Skip to content

Instantly share code, notes, and snippets.

@iperelivskiy
Created November 21, 2012 12:24
Show Gist options
  • Save iperelivskiy/4124616 to your computer and use it in GitHub Desktop.
Save iperelivskiy/4124616 to your computer and use it in GitHub Desktop.
Base64 string regex
BASE64_STRING_REGEX = ''.join((r'(?:[A-Za-z0-9+/]{4})*',
r'(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?'))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment