crypto

All function in this module take and return bytes

class steam.core.crypto.UniverseKey

Public keys for Universes

Public = <cryptography.hazmat.backends.openssl.rsa._RSAPublicKey object>
steam.core.crypto.pad(s)
steam.core.crypto.unpad(s)
steam.core.crypto.generate_session_key(hmac_secret='')
Parameters:hmac_secret (bytes) – optional HMAC
Returns:(session_key, encrypted_session_key) tuple
Return type:tuple
steam.core.crypto.symmetric_encrypt(message, key)
steam.core.crypto.symmetric_encrypt_HMAC(message, key, hmac_secret)
steam.core.crypto.symmetric_encrypt_iv(iv, key)
steam.core.crypto.symmetric_encrypt_with_iv(message, key, iv)
steam.core.crypto.symmetric_decrypt(cyphertext, key)
steam.core.crypto.symmetric_decrypt_HMAC(cyphertext, key, hmac_secret)
Raises:RuntimeError when HMAC verification fails
steam.core.crypto.symmetric_decrypt_iv(cyphertext, key)
steam.core.crypto.symmetric_decrypt_with_iv(cyphertext, key, iv)
steam.core.crypto.hmac_sha1(secret, data)
steam.core.crypto.sha1_hash(data)