Python rfc822.unquote() Examples

The following are 20 code examples of rfc822.unquote(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module rfc822 , or try the search function .
Example #1
Source File: mimetools.py    From medicare-demo with Apache License 2.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #2
Source File: mimetools.py    From CTFCrackTools with GNU General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #3
Source File: mimetools.py    From CTFCrackTools with GNU General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #4
Source File: mimetools.py    From canape with GNU General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #5
Source File: mimetools.py    From unity-python with MIT License 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #6
Source File: mimetools.py    From PokemonGo-DesktopMap with MIT License 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #7
Source File: mimetools.py    From RevitBatchProcessor with GNU General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #8
Source File: mimetools.py    From CTFCrackTools-V2 with GNU General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #9
Source File: mimetools.py    From CTFCrackTools-V2 with GNU General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #10
Source File: test_rfc822.py    From medicare-demo with Apache License 2.0 5 votes vote down vote up
def test_quote_unquote(self):
        eq = self.assertEqual
        eq(rfc822.quote('foo\\wacky"name'), 'foo\\\\wacky\\"name')
        eq(rfc822.unquote('"foo\\\\wacky\\"name"'), 'foo\\wacky"name') 
Example #11
Source File: mimetools.py    From meddle with MIT License 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #12
Source File: mimetools.py    From Splunking-Crime with GNU Affero General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #13
Source File: mimetools.py    From datafari with Apache License 2.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #14
Source File: mimetype.py    From qpid-python with Apache License 2.0 5 votes vote down vote up
def value(self):
    if self.matches(TOKEN):
      return self.eat().value
    elif self.matches(STRING):
      return rfc822.unquote(self.eat().value)
    else:
      raise ParseError(self.next(), TOKEN, STRING) 
Example #15
Source File: mimetools.py    From pmatic with GNU General Public License v2.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #16
Source File: mimetools.py    From oss-ftp with MIT License 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #17
Source File: mimetools.py    From Computable with MIT License 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #18
Source File: mimetools.py    From BinderFilter with MIT License 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #19
Source File: mimetools.py    From GDCTSCP with GNU Affero General Public License v3.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None 
Example #20
Source File: mimetools.py    From ironpython2 with Apache License 2.0 5 votes vote down vote up
def getparam(self, name):
        name = name.lower() + '='
        n = len(name)
        for p in self.plist:
            if p[:n] == name:
                return rfc822.unquote(p[n:])
        return None