function parseDate(date_string) {
	var parts = date_string.split(' '),
		months = {
			'January': 0, 'February': 1, 'March': 2, 'April': 3,
			'May': 4, 'June': 5, 'July': 6, 'August': 7,
			'September': 8, 'October': 9, 'November': 10, 'December': 11
		};

	var month = months[parts[0]],
		day = parseInt(parts[1].replace(',', ''), 10),
		year = parseInt(parts[2], 10);

	var date = new Date(year, month, day);

	return Math.floor(date.getTime() / 1000);
}

var licenses = JSON.parse(value),
	result = {
		response: {
			'@status': 'success',
			data: []
		}
	};

if (licenses.response['@status'] !== 'success') {
	licenses.response.data = [];
	return JSON.stringify(licenses);
}

if (licenses.response.result && licenses.response.result.licenses && licenses.response.result.licenses.entry) {
	result.response.data = Array.isArray(licenses.response.result.licenses.entry) ? licenses.response.result.licenses.entry : [licenses.response.result.licenses.entry];

	for (var i in result.response.data) {
		if (result.response.data[i].expires !== 'Never') {
			result.response.data[i].expires = parseDate(result.response.data[i].expires);
		}
	}

	return JSON.stringify(result);
}

return JSON.stringify(result);