(auth)
| 317 | |
| 318 | |
| 319 | def decode_auth(auth): |
| 320 | if isinstance(auth, str): |
| 321 | auth = auth.encode('ascii') |
| 322 | s = base64.b64decode(auth) |
| 323 | login, pwd = s.split(b':', 1) |
| 324 | return login.decode('utf8'), pwd.decode('utf8') |
| 325 | |
| 326 | |
| 327 | def encode_header(auth): |
no outgoing calls
no test coverage detected