from binascii import hexlify, unhexlify
from Crypto.Cipher import AES
IV = 16*"\x00"
key = 16*"\x00"
picc = "CACDEC6C5455EE52BB1DA40470963113"
myaes = AES.new(key,AES.MODE_CBC,IV)
okay = myaes.decrypt(unhexlify(picc))
counter=int("0x"+hexlify(okay[9:10])+hexlify(okay[8:9]),16)
print counter
ZnJvbSBiaW5hc2NpaSBpbXBvcnQgaGV4bGlmeSwgdW5oZXhsaWZ5CmZyb20gQ3J5cHRvLkNpcGhlciBpbXBvcnQgQUVTCklWICAgICA9IDE2KiJceDAwIgprZXkgICAgPSAxNioiXHgwMCIKcGljYyAgID0gIkNBQ0RFQzZDNTQ1NUVFNTJCQjFEQTQwNDcwOTYzMTEzIgpteWFlcyAgPSBBRVMubmV3KGtleSxBRVMuTU9ERV9DQkMsSVYpCm9rYXkgICA9IG15YWVzLmRlY3J5cHQodW5oZXhsaWZ5KHBpY2MpKQpjb3VudGVyPWludCgiMHgiK2hleGxpZnkob2theVs5OjEwXSkraGV4bGlmeShva2F5Wzg6OV0pLDE2KQpwcmludCAgIGNvdW50ZXIK