News for hackers. Stuff that matters.
Re:GitHub will require 2FA by the end of 2023 by jesushax on Thursday May 05, 2022 @12:36PM (#31275531)
Okay, subreddit created: https://www.reddit.com/r/encrypted_gb_codes/

I mispelled gh as gb, but that makes it more memorable (Great Britain, world war II spies, the cryptonomicon partially taking place in the UK, easy peasy).

Okay, so where was I? Right, the encrypted backup codes! Here is the code

    encrypted = []

    secret_key = input('secret key: ')

    try:
        for index, character in enumerate(input('secret to encrypt: ')):
            encrypted.append(ord(character) ^ ord(secret_key[index]))
    except IndexError:
        print('Your key is not big enough to securely encrypt the secret!')
        print('Go play cryptopals to see why using XOR that way would be bad')

    print(''.join(hex(i) for i in encrypted))
Aaand the secret is live on reddit. For redundancy I need to plaster this everywhere (hiding it in public key exchanges would also be easy!), but this will do for now:

https://www.reddit.com/r/encrypted_gb_codes/comments/uj1fll/...

There are no comments on this comment yet.