Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#28 Fix to avoid TypeError exception #30

Merged
merged 2 commits into from
Sep 14, 2017
Merged

Conversation

jonasao
Copy link

@jonasao jonasao commented Sep 14, 2017

Converted both username and password arguments to byte arrays upon contatenating them to the string sent to the digest() method of the hash_class. Converted str to byte array in call to h.update() in the calculate_M() method.

@cocagne cocagne merged commit 8f0362d into cocagne:master Sep 14, 2017
@cocagne
Copy link
Owner

cocagne commented Apr 5, 2018 via email

@dragomirecky
Copy link
Contributor

Ha, thanks for having a look even when I deleted the comment :). After I wrote it, I realized this merge request is from September 2017 but my fork of the library from January 2018 did not have the problem. I wanted to get back to it today.

Have you done some changes to git history or what reintroduced the problem?

Nevertheless, one more thanks for fixing it so quickly :)

@cocagne
Copy link
Owner

cocagne commented Apr 5, 2018 via email

@dragomirecky
Copy link
Contributor

Steps to reproduce:

  1. pip install --upgrade --force-reinstall srp==1.0.11
  2. python -c 'import srp; srp.create_salted_verification_key(b"user", b"password")'

That is all it takes (Python 3.6.1).

I just confirmed that your update fixes the issue. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants