2013-04-15 1 views
0

je suis un novice en python, et je ne peux pas faire de stuf facile. J'ai un code de JavaPython, cast Entier en octets.

raw[j] = (byte) (chksum & 0xff) 
raw[j + 1] = (byte) (chksum >> 0x08 & 0xff) 
raw[j + 2] = (byte) (chksum >> 0x10 & 0xff) 
raw[j + 3] = (byte) (chksum >> 0x18 & 0xff) 

Où brut est un tableau d'octets que je dois le faire en python. Mais comment puis-je lancer int aux octets? Et peut-être que quelqu'un sait où puis-je obtenir la bibliothèque pour l'utilisation de cryptage Blowfish?

Répondre