'Parse a text response for a PDT verification .
:param response str: text response, structured in the following way:
STATUS
key1=value1
key2=value2...
or STATUS
Error message...
:rtype tuple(str, dict)
:return: tuple containing the STATUS str and the key/value pairs
parsed as a dict'

def _parse_pdt_response(self, response):

    lines = filter(None, response.split('\n'))
    status = lines.pop(0)
    pdt_post = {}
    for line in lines:
        split = line.split('=', 1)
        if (len(split) == 2):
            pdt_post[split[0]] = urllib.unquote_plus(split[1]).decode('utf8')
        else:
            _logger.warning('Paypal:    error    processing    pdt    response:    %s', line)
    return (status, pdt_post)
