Tootfinder

Opt-in global Mastodon full text search. Join the index!

@niqdanger@social.linux.pizza
2025-09-19 20:39:33

Whats the replacement for crypt in python? I want to crypt a known string just like /etc/shadow/ so I can verify my students set the username/pw correctly as requested in a lab. I was using this code (image) but looks like crypt.crypt isn't there in Python3.13. Looks like my code doesn't work like it did last semester. Oops. #python3

Snippit of python code showing reading a crypted PW from shadow, then encrpyting a string with the same salt to compare if password was set correctly in a student exam.