:py:mod:`cryptnoxpy.cryptos` ============================ .. py:module:: cryptnoxpy.cryptos Submodules ---------- .. toctree:: :titlesonly: :maxdepth: 1 main/index.rst py2specials/index.rst py3specials/index.rst ripemd/index.rst Package Contents ---------------- Classes ~~~~~~~ .. autoapisummary:: cryptnoxpy.cryptos.RIPEMD160 cryptnoxpy.cryptos.RMDContext Functions ~~~~~~~~~ .. autoapisummary:: cryptnoxpy.cryptos.change_curve cryptnoxpy.cryptos.getG cryptnoxpy.cryptos.inv cryptnoxpy.cryptos.access cryptnoxpy.cryptos.multiaccess cryptnoxpy.cryptos.slice cryptnoxpy.cryptos.count cryptnoxpy.cryptos.sum cryptnoxpy.cryptos.isinf cryptnoxpy.cryptos.to_jacobian cryptnoxpy.cryptos.jacobian_double cryptnoxpy.cryptos.jacobian_add cryptnoxpy.cryptos.fast_add cryptnoxpy.cryptos.get_pubkey_format cryptnoxpy.cryptos.encode_pubkey cryptnoxpy.cryptos.decode_pubkey cryptnoxpy.cryptos.get_privkey_format cryptnoxpy.cryptos.encode_privkey cryptnoxpy.cryptos.decode_privkey cryptnoxpy.cryptos.add_pubkeys cryptnoxpy.cryptos.add_privkeys cryptnoxpy.cryptos.divide cryptnoxpy.cryptos.compress cryptnoxpy.cryptos.decompress cryptnoxpy.cryptos.neg_pubkey cryptnoxpy.cryptos.neg_privkey cryptnoxpy.cryptos.subtract_pubkeys cryptnoxpy.cryptos.subtract_privkeys cryptnoxpy.cryptos.bin_hash160 cryptnoxpy.cryptos.hash160 cryptnoxpy.cryptos.hex_to_hash160 cryptnoxpy.cryptos.bin_sha256 cryptnoxpy.cryptos.sha256 cryptnoxpy.cryptos.bin_ripemd160 cryptnoxpy.cryptos.ripemd160 cryptnoxpy.cryptos.bin_dbl_sha256 cryptnoxpy.cryptos.dbl_sha256 cryptnoxpy.cryptos.bin_slowsha cryptnoxpy.cryptos.slowsha cryptnoxpy.cryptos.hash_to_int cryptnoxpy.cryptos.num_to_var_int cryptnoxpy.cryptos.electrum_sig_hash cryptnoxpy.cryptos.b58check_to_bin cryptnoxpy.cryptos.get_version_byte cryptnoxpy.cryptos.hex_to_b58check cryptnoxpy.cryptos.b58check_to_hex cryptnoxpy.cryptos.pubkey_to_hash cryptnoxpy.cryptos.pubkey_to_hash_hex cryptnoxpy.cryptos.pubkey_to_address cryptnoxpy.cryptos.is_privkey cryptnoxpy.cryptos.is_pubkey cryptnoxpy.cryptos.encode_sig cryptnoxpy.cryptos.decode_sig cryptnoxpy.cryptos.deterministic_generate_k cryptnoxpy.cryptos.ecdsa_verify_addr cryptnoxpy.cryptos.ecdsa_verify cryptnoxpy.cryptos.add cryptnoxpy.cryptos.subtract cryptnoxpy.cryptos.magicbyte_to_prefix cryptnoxpy.cryptos.new cryptnoxpy.cryptos.ROL cryptnoxpy.cryptos.F0 cryptnoxpy.cryptos.F1 cryptnoxpy.cryptos.F2 cryptnoxpy.cryptos.F3 cryptnoxpy.cryptos.F4 cryptnoxpy.cryptos.R cryptnoxpy.cryptos.RMD160Transform cryptnoxpy.cryptos.RMD160Update cryptnoxpy.cryptos.RMD160Final Attributes ~~~~~~~~~~ .. autoapisummary:: cryptnoxpy.cryptos.P cryptnoxpy.cryptos.N cryptnoxpy.cryptos.A cryptnoxpy.cryptos.B cryptnoxpy.cryptos.Gx cryptnoxpy.cryptos.Gy cryptnoxpy.cryptos.G cryptnoxpy.cryptos._sum cryptnoxpy.cryptos.pubtoaddr cryptnoxpy.cryptos.hash160Low cryptnoxpy.cryptos.hash160High cryptnoxpy.cryptos.string_types cryptnoxpy.cryptos.is_python2 cryptnoxpy.cryptos.digest_size cryptnoxpy.cryptos.digestsize cryptnoxpy.cryptos.range cryptnoxpy.cryptos.K0 cryptnoxpy.cryptos.K1 cryptnoxpy.cryptos.K2 cryptnoxpy.cryptos.K3 cryptnoxpy.cryptos.K4 cryptnoxpy.cryptos.KK0 cryptnoxpy.cryptos.KK1 cryptnoxpy.cryptos.KK2 cryptnoxpy.cryptos.KK3 cryptnoxpy.cryptos.KK4 cryptnoxpy.cryptos.PADDING cryptnoxpy.cryptos.string_types cryptnoxpy.cryptos.string_types .. py:data:: P .. py:data:: N :annotation: = 115792089237316195423570985008687907852837564279074904382605163141518161494337 .. py:data:: A :annotation: = 0 .. py:data:: B :annotation: = 7 .. py:data:: Gx :annotation: = 55066263022277343669578718895168534326250603453777594175500187360389116729240 .. py:data:: Gy :annotation: = 32670510020758816978083085130507043184471273380659243275938904335757337482424 .. py:data:: G .. py:function:: change_curve(p, n, a, b, gx, gy) .. py:function:: getG() .. py:function:: inv(a, n) .. py:function:: access(obj, prop) .. py:function:: multiaccess(obj, prop) .. py:function:: slice(obj, start=0, end=2**200) .. py:function:: count(obj) .. py:data:: _sum .. py:function:: sum(obj) .. py:function:: isinf(p) .. py:function:: to_jacobian(p) .. py:function:: jacobian_double(p) .. py:function:: jacobian_add(p, q) .. py:function:: fast_add(a, b) .. py:function:: get_pubkey_format(pub) .. py:function:: encode_pubkey(pub, formt) .. py:function:: decode_pubkey(pub, formt=None) .. py:function:: get_privkey_format(priv) .. py:function:: encode_privkey(priv, formt, vbyte=128) .. py:function:: decode_privkey(priv, formt=None) .. py:function:: add_pubkeys(p1, p2) .. py:function:: add_privkeys(p1, p2) .. py:function:: divide(pubkey, privkey) .. py:function:: compress(pubkey) .. py:function:: decompress(pubkey) .. py:function:: neg_pubkey(pubkey) .. py:function:: neg_privkey(privkey) .. py:function:: subtract_pubkeys(p1, p2) .. py:function:: subtract_privkeys(p1, p2) .. py:function:: bin_hash160(string) .. py:function:: hash160(string) .. py:function:: hex_to_hash160(s_hex) .. py:function:: bin_sha256(string) .. py:function:: sha256(string) .. py:function:: bin_ripemd160(string) .. py:function:: ripemd160(string) .. py:function:: bin_dbl_sha256(s) .. py:function:: dbl_sha256(string) .. py:function:: bin_slowsha(string) .. py:function:: slowsha(string) .. py:function:: hash_to_int(x) .. py:function:: num_to_var_int(x) .. py:function:: electrum_sig_hash(message) .. py:function:: b58check_to_bin(inp) .. py:function:: get_version_byte(inp) .. py:function:: hex_to_b58check(inp, magicbyte=0) .. py:function:: b58check_to_hex(inp) .. py:function:: pubkey_to_hash(pubkey) .. py:function:: pubkey_to_hash_hex(pubkey) .. py:function:: pubkey_to_address(pubkey, magicbyte=0) .. py:data:: pubtoaddr .. py:function:: is_privkey(priv) .. py:function:: is_pubkey(pubkey) .. py:function:: encode_sig(v, r, s) .. py:function:: decode_sig(sig) .. py:function:: deterministic_generate_k(msghash, priv) .. py:function:: ecdsa_verify_addr(msg, sig, addr, coin) .. py:function:: ecdsa_verify(msg, sig, pub, coin) .. py:function:: add(p1, p2) .. py:function:: subtract(p1, p2) .. py:data:: hash160Low :annotation: = b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00' .. py:data:: hash160High :annotation: = b'\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff' .. py:function:: magicbyte_to_prefix(magicbyte) .. py:data:: string_types .. py:data:: is_python2 .. py:data:: digest_size :annotation: = 20 .. py:data:: digestsize :annotation: = 20 .. py:data:: range .. py:class:: RIPEMD160(arg=None) Return a new RIPEMD160 object. An optional string argument may be provided; if present, this string will be automatically hashed. .. py:method:: update(self, arg) update(arg) .. py:method:: digest(self) digest() .. py:method:: hexdigest(self) hexdigest() .. py:method:: copy(self) copy() .. py:function:: new(arg=None) Return a new RIPEMD160 object. An optional string argument may be provided; if present, this string will be automatically hashed. .. py:class:: RMDContext .. py:method:: copy(self) .. py:data:: K0 :annotation: = 0 .. py:data:: K1 :annotation: = 1518500249 .. py:data:: K2 :annotation: = 1859775393 .. py:data:: K3 :annotation: = 2400959708 .. py:data:: K4 :annotation: = 2840853838 .. py:data:: KK0 :annotation: = 1352829926 .. py:data:: KK1 :annotation: = 1548603684 .. py:data:: KK2 :annotation: = 1836072691 .. py:data:: KK3 :annotation: = 2053994217 .. py:data:: KK4 :annotation: = 0 .. py:function:: ROL(n, x) .. py:function:: F0(x, y, z) .. py:function:: F1(x, y, z) .. py:function:: F2(x, y, z) .. py:function:: F3(x, y, z) .. py:function:: F4(x, y, z) .. py:function:: R(a, b, c, d, e, Fj, Kj, sj, rj, X) .. py:data:: PADDING .. py:function:: RMD160Transform(state, block) .. py:function:: RMD160Update(ctx, inp, inplen) .. py:function:: RMD160Final(ctx) .. py:data:: string_types .. py:data:: string_types