Hashlib is a Python module that implements a common interface to many different secure hash and message digest algorithms.
Questions tagged [hashlib]
427 questions
-1
votes
1 answer
How can I run a tkinter GUI application without getting freeze..?
Sorry for my bad English.
I made a file hashing app with tkinter and python3 but as soon it start hashing files User Interface get freeze.
How can I prevent it...?
-1
votes
1 answer
Creating a situation-dependent dictionary (hashlib)
The following code is part of a bigger project:
# Todo: automatically generate dict based
# on hashlib.algorithms_available
algorithms = {"md5":hashlib.md5,
"sha1":hashlib.sha1,
"sha224":hashlib.sha224,
…

Daniel
- 769
- 8
- 21
-1
votes
1 answer
How to hash only value to right of "=" sign (or any other delimiter) and output new text file
i outputted a text file based on user input from csv file, in certain format (with help from user suggestions). Now i want to hash only value to right of "=" sign and output new text file with same format but hashed values to right. here is code…

tmdb
- 1
- 2
-1
votes
1 answer
ruby script for cloudfront invalidation 2014-10-21
I want equivalent of
hashlib.sha256("Development").hexdigest() of python in ruby script
Kindly suggest as soon as possible.
I am using it for aws cloudfront.
Kindly suggest some ruby scripts for cloudfront invalidation on…

Kunaparaju
- 13
- 4
-1
votes
1 answer
What are preferred cryptographic hashing functions in Python (preferably provided in hashlib)?
I thought this would be covered by https://docs.python.org/2/library/hashlib.html or by a question on StackOverflow, but I didn't find it covered.
What are reasonably cryptographically strong ways to create a hash code for X many bytes in Python,…

Christos Hayward
- 5,777
- 17
- 58
- 113
-1
votes
1 answer
how to add hashlib++ library to visual studio 2012
I have recently downloaded the "hash lib++" library from it's own site.
but i have problems adding it to visual studio 2012 .I have tried adding it in additional include directories but it was not a successful attempt.I am new to c++ so if you could…

user3092602
- 1
- 2
-1
votes
1 answer
hashlib md5 doesn't actually turn into md5?
I have been using the following code to convert a string into an md5 hash:
password = passwd.hexdigest()
passwd is supposed to be 'test123' so it is supposedly turning that into an md5 hash.
It gives me the…

Jason Decastro
- 45
- 1
- 8
-2
votes
0 answers
Difference between BouncyCastle and Python hashlib
It seems that MD5Digest in BouncyCastle and hashlib.md5 in Python produce different results.
Why is that?
C#:
static string Hash(string str)
{
var utf = System.Text.Encoding.UTF8.GetBytes(str);
var md5 = new…
-2
votes
2 answers
Comparing 2 hash values returning False even though they are the same
How the program works is that the user sends 2 inputs over (userinput and passwordinput).
These are compared against the filename of a textfile (which is the username) and the context (which is the hashed password). The passwordinput gets hashed and…

null
- 147
- 1
- 14
-2
votes
2 answers
I want to calculate the sha256 hashed function for 4digits numbers
I want to calculate the hashed format of the 4 digits password and save it into a dictionary to match it with the password files that I have. But there is a problem. can you help me with this?
Hashed_Passwords=list()
for i in range(1000,1010):
…
-2
votes
1 answer
How to hash sha256 many times in python
I want to hash my password many times but it's hard to repeat codes many times depends on exponent.
So, for example in this code for exponent 2 and base 3:
3**2= 9
So I need to hash my password nine times!
I scanned all the web to find any code…

tony
- 1
- 2
-2
votes
1 answer
Best way of comparing two files in python and why?
I have two files a.txt and b.txt, So i am trying to compare using hash like below.
#getting hash of files and comparing
file1 = hashlib.md5(open('a.txt', 'rb').read()).hexdigest()
file2 = hashlib.md5(open('b.txt', 'rb').read()).hexdigest()…

praveen jp
- 65
- 10
-2
votes
1 answer
Understand what hexdigest do?
a = hashlib.sha512("data").hexdigest()[:32]
What is signifance of using hexdigest here ?

cryptoKTM
- 2,593
- 22
- 21
-2
votes
1 answer
Getting error while encrypting the password using salt in Python
I am getting error while encrypting the password using Python. I am explaining the error below.
Error:
Traceback (most recent call last):
File "password.py", line 60, in
hashed_password = hashlib.sha512(sword +…
user5443928
-2
votes
1 answer
Can't encrypt a string and insert it into sqlite
I'm trying to store an password into a sqlite database here's the error:
Traceback (most recent call last):
File "/media/luis/Vista/Users/Administrador/PycharmProjects/PNV/sqlitetesting.py", line 33, in
""", encriptado)
TypeError:…

Luís Duarte
- 39
- 1
- 7