onetimepass
onetimepass copied to clipboard
Autopad secrets
Discussed in #20. This changeset makes @hobarrera's example accepted without manual padding.
The funny looking for length in [2, 4, 5, 7, 10, 12, 13, 15]: in the tests is to match the if-else cascade in Lib/base64.py:
https://github.com/python/cpython/blob/c7ff163abf428d73d4054754db3c99d06487e3ad/Lib/base64.py#L170
The autopad functionality was controlled by parameter which I then removed in commit b1e5d0a. If you want to keep it optional, delete that commit.
Thanks, corrected the version.
Also removed a call to a pseudoprivate base64.py method, which fixed some CI jobs. The Travis config looks like it still needs an update, with timecop refusing to run below 3.3.
Timecop apparently dropped py33. freezegun looks like it covers the same use cases and is a lot more mature.
This PR fixes the situation when trying to use onetimepass to generate codes for amazon.com service to login. Looks like all amazon.com secrets for 2FA cause the underlying issue. Can we merge this PR please?
@tadeck , @WhyNotHugo - ping. Can I help in any way to get this merged faster?
@tadeck , @WhyNotHugo - ping. Can I help in any way to get this merged faster?
Apparently the build is failing: https://travis-ci.org/github/tadeck/onetimepass/builds/243858616 Looks like this PR is a welcome change, happy to merge it after we get through with making the builds green again.
Can we drop 3.2 version of Python? See .travis.yml: line 5
The build fail specifically because some requirements don't work with versions of Python 3.x below 3.3.
Dropping Python 3.2 sounds reasonable to me (note: I'm not a maintainer here, but still, that version is waaay past it's end of life).
OK - I have a PR for dropping v3.2 of Python - https://github.com/tadeck/onetimepass/pull/30 . We should merge that one first.