Copyright | (c) Dong Han 2020 - 2021 |
---|---|
License | BSD |
Maintainer | winterland1989@gmail.com |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell2010 |
INTERNAL MODULE, provides all botan FFI defs.
Synopsis
- hs_botan_allocate_memory :: Int -> IO (Ptr Word8)
- hs_botan_deallocate_memory_p :: FunPtr (Ptr Word8 -> Ptr Word8 -> IO ())
- hs_botan_deallocate_memory :: Ptr Word8 -> Ptr Word8 -> IO ()
- botan_constant_time_compare_ba :: BA# Word8 -> BA# Word8 -> CSize -> CInt
- botan_constant_time_compare :: Ptr Word8 -> Ptr Word8 -> CSize -> CInt
- allocBotanBufferUTF8Unsafe :: (HasCallStack, Integral r) => Int -> (MBA# Word8 -> MBA# CSize -> IO r) -> IO Text
- allocBotanBufferUnsafe :: (HasCallStack, Integral r) => Int -> (MBA# Word8 -> MBA# CSize -> IO r) -> IO Bytes
- type BotanStruct = CPtr ()
- type BotanStructT = Ptr ()
- withBotanStruct :: BotanStruct -> (BotanStructT -> IO a) -> IO a
- newBotanStruct :: HasCallStack => (MBA# BotanStructT -> IO CInt) -> FunPtr (BotanStructT -> IO a) -> IO BotanStruct
- newBotanStruct' :: HasCallStack => (Ptr BotanStructT -> IO CInt) -> FunPtr (BotanStructT -> IO a) -> IO BotanStruct
- botan_rng_init :: MBA# BotanStructT -> BA# Word8 -> IO CInt
- botan_rng_destroy :: FunPtr (BotanStructT -> IO ())
- botan_rng_get :: BotanStructT -> MBA# Word8 -> CSize -> IO CInt
- botan_rng_reseed :: BotanStructT -> CSize -> IO CInt
- botan_rng_reseed_from_rng :: BotanStructT -> BotanStructT -> CSize -> IO CInt
- hs_botan_rng_add_entropy :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_mp_init :: MBA# BotanStructT -> IO CInt
- botan_mp_destroy :: FunPtr (BotanStructT -> IO ())
- botan_mp_set_from_int :: BotanStructT -> CInt -> IO CInt
- botan_mp_set_from_mp :: BotanStructT -> BotanStructT -> IO CInt
- botan_mp_num_bytes :: BotanStructT -> MBA# CSize -> IO CInt
- botan_mp_num_bits :: BotanStructT -> MBA# CSize -> IO CInt
- hs_botan_mp_to_hex :: BotanStructT -> MBA# Word8 -> Int -> IO CInt
- hs_botan_mp_to_dec :: BotanStructT -> MBA# Word8 -> Int -> IO Int
- hs_botan_mp_set_from_hex :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_mp_set_from_dec :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_mp_to_bin :: BotanStructT -> MBA# Word8 -> Int -> IO CInt
- hs_botan_mp_from_bin :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_mp_flip_sign :: BotanStructT -> IO CInt
- botan_mp_add :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_sub :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_mul :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_div :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_mod_mul :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_equal :: BotanStructT -> BotanStructT -> IO CInt
- botan_mp_is_zero :: BotanStructT -> IO CInt
- botan_mp_is_odd :: BotanStructT -> IO CInt
- botan_mp_is_even :: BotanStructT -> IO CInt
- botan_mp_is_positive :: BotanStructT -> IO CInt
- botan_mp_is_negative :: BotanStructT -> IO CInt
- botan_mp_to_uint32 :: BotanStructT -> MBA# Word32 -> IO CInt
- botan_mp_cmp :: MBA# CInt -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_swap :: BotanStructT -> BotanStructT -> IO ()
- botan_mp_powmod :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_lshift :: BotanStructT -> BotanStructT -> CSize -> IO CInt
- botan_mp_rshift :: BotanStructT -> BotanStructT -> CSize -> IO CInt
- botan_mp_mod_inverse :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_rand_bits :: BotanStructT -> BotanStructT -> CSize -> IO CInt
- botan_mp_rand_range :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_gcd :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_mp_is_prime :: BotanStructT -> BotanStructT -> CSize -> IO CInt
- botan_mp_get_bit :: BotanStructT -> CSize -> IO CInt
- botan_mp_set_bit :: BotanStructT -> CSize -> IO CInt
- botan_mp_clear_bit :: BotanStructT -> CSize -> IO CInt
- botan_block_cipher_init :: MBA# BotanStructT -> BA# Word8 -> IO CInt
- botan_block_cipher_destroy :: FunPtr (BotanStructT -> IO ())
- botan_block_cipher_block_size :: BotanStructT -> IO CInt
- botan_block_cipher_get_keyspec :: BotanStructT -> MBA# Int -> MBA# Int -> MBA# Int -> IO CInt
- botan_block_cipher_clear :: BotanStructT -> IO CInt
- botan_block_cipher_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt
- hs_botan_block_cipher_encrypt_blocks :: BotanStructT -> BA# Word8 -> Int -> MBA# Word8 -> Int -> IO CInt
- hs_botan_block_cipher_decrypt_blocks :: BotanStructT -> BA# Word8 -> Int -> MBA# Word8 -> Int -> IO CInt
- botan_hash_init :: MBA# BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_hash_destroy :: FunPtr (BotanStructT -> IO ())
- botan_hash_copy_state :: MBA# BotanStructT -> BotanStructT -> IO CInt
- botan_hash_clear :: BotanStructT -> IO CInt
- botan_hash_output_length :: BotanStructT -> MBA# CSize -> IO CInt
- hs_botan_hash_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_hash_final :: BotanStructT -> MBA# Word8 -> IO CInt
- data CipherDirection
- cipherDirectionToFlag :: CipherDirection -> Word32
- botan_cipher_init :: MBA# BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_cipher_destroy :: FunPtr (BotanStructT -> IO ())
- botan_cipher_clear :: BotanStructT -> IO CInt
- botan_cipher_get_keyspec :: BotanStructT -> MBA# CSize -> MBA# CSize -> MBA# CSize -> IO CInt
- botan_cipher_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt
- hs_botan_cipher_start :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_cipher_finish :: BotanStructT -> MBA# Word8 -> Int -> BA# Word8 -> Int -> Int -> IO Int
- hs_botan_cipher_set_associated_data :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_cipher_valid_nonce_length :: BotanStructT -> CSize -> IO CInt
- botan_cipher_get_default_nonce_length :: BotanStructT -> MBA# Int -> IO CInt
- botan_cipher_get_tag_length :: BotanStructT -> MBA# Int -> IO CInt
- hs_botan_cipher_output_size :: BotanStructT -> Int -> IO Int
- botan_stream_cipher_init :: MBA# BotanStructT -> BA# Word8 -> IO CInt
- botan_stream_cipher_destroy :: FunPtr (BotanStructT -> IO ())
- botan_stream_cipher_seek :: BotanStructT -> CSize -> IO CInt
- botan_stream_cipher_clear :: BotanStructT -> IO CInt
- botan_stream_cipher_get_keyspec :: BotanStructT -> MBA# CSize -> MBA# CSize -> MBA# CSize -> IO CInt
- botan_stream_cipher_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt
- hs_botan_stream_cipher_set_iv :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_stream_cipher_cipher :: BotanStructT -> MBA# Word8 -> BA# Word8 -> Int -> Int -> IO CInt
- botan_stream_cipher_write_keystream :: BotanStructT -> MBA# Word8 -> CSize -> IO CInt
- botan_stream_cipher_valid_iv_length :: BotanStructT -> CSize -> IO CInt
- botan_stream_cipher_get_default_iv_length :: BotanStructT -> MBA# Int -> IO CInt
- hs_botan_pwdhash :: BA# Word8 -> Int -> Int -> Int -> Ptr Word8 -> Int -> BA# Word8 -> Int -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_pwdhash_timed :: BA# Word8 -> Int -> Ptr Word8 -> Int -> BA# Word8 -> Int -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_pwdhash_timed_safe :: Ptr Word8 -> Int -> Ptr Word8 -> Int -> Ptr Word8 -> Int -> Ptr Word8 -> Int -> Int -> IO CInt
- hs_botan_kdf :: BA# Word8 -> Ptr Word8 -> CSize -> Ptr Word8 -> CSize -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> Int -> IO CInt
- botan_bcrypt_generate :: MBA# Word8 -> MBA# CSize -> BA# Word8 -> BotanStructT -> Int -> Word32 -> IO CInt
- hs_botan_bcrypt_is_valid :: BA# Word8 -> BA# Word8 -> Int -> Int -> IO CInt
- botan_mac_init :: MBA# BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_mac_destroy :: FunPtr (BotanStructT -> IO ())
- botan_mac_output_length :: BotanStructT -> MBA# CSize -> IO CInt
- botan_mac_final :: BotanStructT -> MBA# Word8 -> IO CInt
- botan_mac_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt
- hs_botan_mac_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_mac_clear :: BotanStructT -> IO CInt
- hs_botan_mac_name :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- hs_botan_mac_get_keyspec :: BotanStructT -> MBA# Int -> MBA# Int -> MBA# Int -> IO CInt
- botan_privkey_create :: Ptr BotanStructT -> Ptr Word8 -> Ptr Word8 -> BotanStructT -> IO CInt
- hs_botan_privkey_load :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> BA# Word8 -> IO CInt
- botan_privkey_export :: BotanStructT -> MBA# Word8 -> MBA# CSize -> Word32 -> IO CInt
- botan_privkey_export_encrypted :: BotanStructT -> MBA# Word8 -> MBA# CSize -> BotanStructT -> BA# Word8 -> BA# Word8 -> Word32 -> IO CInt
- botan_privkey_export_pubkey :: MBA# BotanStructT -> BotanStructT -> IO CInt
- botan_privkey_get_field :: BotanStructT -> BotanStructT -> BA# Word8 -> IO CInt
- botan_privkey_destroy :: FunPtr (BotanStructT -> IO ())
- hs_botan_pubkey_load :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_pubkey_export :: BotanStructT -> MBA# Word8 -> MBA# CSize -> Word32 -> IO CInt
- botan_privkey_algo_name :: BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt
- botan_pubkey_algo_name :: BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt
- botan_pubkey_estimated_strength :: BotanStructT -> MBA# CSize -> IO CInt
- botan_pubkey_fingerprint :: BotanStructT -> BA# Word8 -> MBA# Word8 -> MBA# CSize -> IO CInt
- botan_pubkey_destroy :: FunPtr (BotanStructT -> IO ())
- botan_pubkey_get_field :: BotanStructT -> BotanStructT -> BA# Word8 -> IO CInt
- botan_privkey_load_rsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_pubkey_load_rsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_privkey_load_dsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_pubkey_load_dsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_privkey_load_elgamal :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_pubkey_load_elgamal :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_privkey_load_dh :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_pubkey_load_dh :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt
- botan_pk_op_encrypt_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_pk_op_encrypt_destroy :: FunPtr (BotanStructT -> IO ())
- botan_pk_op_encrypt_output_length :: BotanStructT -> CSize -> MBA# CSize -> IO CInt
- hs_botan_pk_op_encrypt :: BotanStructT -> BotanStructT -> MBA# Word8 -> MBA# CSize -> BA# Word8 -> Int -> Int -> IO CInt
- botan_pk_op_decrypt_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_pk_op_decrypt_destroy :: FunPtr (BotanStructT -> IO ())
- botan_pk_op_decrypt_output_length :: BotanStructT -> CSize -> MBA# CSize -> IO CInt
- hs_botan_pk_op_decrypt :: BotanStructT -> MBA# Word8 -> MBA# CSize -> BA# Word8 -> Int -> Int -> IO CInt
- botan_pk_op_sign_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_pk_op_sign_output_length :: BotanStructT -> MBA# CSize -> IO CInt
- hs_botan_pk_op_sign_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_pk_op_sign_finish :: BotanStructT -> BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt
- botan_pk_op_sign_destroy :: FunPtr (BotanStructT -> IO ())
- botan_pk_op_verify_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_pk_op_verify_destroy :: FunPtr (BotanStructT -> IO ())
- hs_botan_pk_op_verify_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_pk_op_verify_finish :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_pk_op_key_agreement_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt
- botan_pk_op_key_agreement_destroy :: FunPtr (BotanStructT -> IO ())
- botan_pk_op_key_agreement_export_public :: BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt
- botan_pk_op_key_agreement_size :: BotanStructT -> MBA# CSize -> IO CInt
- hs_botan_pk_op_key_agreement :: BotanStructT -> Ptr Word8 -> CSize -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> Int -> IO CInt
- type KeyUsageConstraint = CUInt
- pattern NO_CONSTRAINTS :: KeyUsageConstraint
- pattern DIGITAL_SIGNATURE :: KeyUsageConstraint
- pattern NON_REPUDIATION :: KeyUsageConstraint
- pattern KEY_ENCIPHERMENT :: KeyUsageConstraint
- pattern DATA_ENCIPHERMENT :: KeyUsageConstraint
- pattern KEY_AGREEMENT :: KeyUsageConstraint
- pattern KEY_CERT_SIGN :: KeyUsageConstraint
- pattern CRL_SIGN :: KeyUsageConstraint
- pattern ENCIPHER_ONLY :: KeyUsageConstraint
- pattern DECIPHER_ONLY :: KeyUsageConstraint
- botan_x509_cert_destroy :: FunPtr (BotanStructT -> IO ())
- hs_botan_x509_cert_load :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_x509_cert_load_file :: MBA# BotanStructT -> BA# Word8 -> IO CInt
- botan_x509_cert_dup :: MBA# BotanStructT -> BotanStructT -> IO CInt
- botan_x509_cert_get_time_starts :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_time_expires :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_not_before :: BotanStructT -> MBA# Word64 -> IO CInt
- botan_x509_cert_not_after :: BotanStructT -> MBA# Word64 -> IO CInt
- botan_x509_cert_get_fingerprint :: BotanStructT -> BA# Word8 -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_serial_number :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_authority_key_id :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_subject_key_id :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_public_key_bits :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_public_key :: BotanStructT -> MBA# BotanStructT -> IO CInt
- botan_x509_cert_get_issuer_dn :: BotanStructT -> BA# Word8 -> Int -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_get_subject_dn :: BotanStructT -> BA# Word8 -> Int -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_to_string :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt
- botan_x509_cert_allowed_usage :: BotanStructT -> CUInt -> IO CInt
- hs_botan_x509_cert_verify :: BotanStructT -> BA# BotanStructT -> Int -> BA# BotanStructT -> Int -> Int -> BA# Word8 -> Word64 -> IO CInt
- hs_botan_x509_cert_verify_with_crl :: BotanStructT -> BA# BotanStructT -> Int -> BA# BotanStructT -> Int -> BA# BotanStructT -> Int -> Int -> BA# Word8 -> Word64 -> IO CInt
- hs_botan_x509_cert_verify_with_certstore_crl :: BotanStructT -> BA# BotanStructT -> Int -> BotanStructT -> BA# BotanStructT -> Int -> Int -> BA# Word8 -> Word64 -> IO CInt
- botan_x509_cert_validation_status :: CInt -> IO CString
- hs_botan_x509_crl_load :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_x509_crl_load_file :: MBA# BotanStructT -> BA# Word8 -> IO CInt
- botan_x509_crl_destroy :: FunPtr (BotanStructT -> IO ())
- botan_x509_is_revoked :: BotanStructT -> BotanStructT -> IO CInt
- botan_x509_certstore_load_file :: MBA# BotanStructT -> BA# Word8 -> IO CInt
- botan_x509_certstore_load_system :: MBA# BotanStructT -> IO CInt
- botan_x509_certstore_destroy :: FunPtr (BotanStructT -> IO ())
- botan_key_wrap3394 :: Ptr Word8 -> CSize -> Ptr Word8 -> CSize -> MBA# Word8 -> MBA# CSize -> IO CInt
- hs_botan_key_unwrap3394 :: BA# Word8 -> Int -> Int -> Ptr Word8 -> CSize -> Ptr Word8 -> CSize -> IO CInt
- hs_botan_hotp_init :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> IO CInt
- botan_hotp_destroy :: FunPtr (BotanStructT -> IO ())
- botan_hotp_generate :: BotanStructT -> MBA# Word32 -> Word64 -> IO CInt
- botan_hotp_check :: BotanStructT -> MBA# Word64 -> Word32 -> Word64 -> CSize -> IO CInt
- hs_botan_totp_init :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> Int -> IO CInt
- botan_totp_destroy :: FunPtr (BotanStructT -> IO ())
- botan_totp_generate :: BotanStructT -> MBA# Word32 -> Word64 -> IO CInt
- botan_totp_check :: BotanStructT -> Word32 -> Word64 -> CSize -> IO CInt
- hs_botan_fpe_fe1_init :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> Int -> Word32 -> IO CInt
- hs_botan_fpe_encrypt :: BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- hs_botan_fpe_decrypt :: BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt
- botan_fpe_destroy :: FunPtr (BotanStructT -> IO ())
Documentation
allocBotanBufferUTF8Unsafe :: (HasCallStack, Integral r) => Int -> (MBA# Word8 -> MBA# CSize -> IO r) -> IO Text Source #
allocBotanBufferUnsafe :: (HasCallStack, Integral r) => Int -> (MBA# Word8 -> MBA# CSize -> IO r) -> IO Bytes Source #
type BotanStruct = CPtr () Source #
Internal type to representation botan struct, botan_xxx_t is always pointer type.
type BotanStructT = Ptr () Source #
withBotanStruct :: BotanStruct -> (BotanStructT -> IO a) -> IO a Source #
:: HasCallStack | |
=> (MBA# BotanStructT -> IO CInt) | init function |
-> FunPtr (BotanStructT -> IO a) | destroy function pointer |
-> IO BotanStruct |
:: HasCallStack | |
=> (Ptr BotanStructT -> IO CInt) | init function |
-> FunPtr (BotanStructT -> IO a) | destroy function pointer |
-> IO BotanStruct |
botan_rng_init :: MBA# BotanStructT -> BA# Word8 -> IO CInt Source #
botan_rng_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_rng_get :: BotanStructT -> MBA# Word8 -> CSize -> IO CInt Source #
botan_rng_reseed :: BotanStructT -> CSize -> IO CInt Source #
botan_rng_reseed_from_rng :: BotanStructT -> BotanStructT -> CSize -> IO CInt Source #
hs_botan_rng_add_entropy :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_mp_init :: MBA# BotanStructT -> IO CInt Source #
botan_mp_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_mp_set_from_int :: BotanStructT -> CInt -> IO CInt Source #
botan_mp_set_from_mp :: BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_num_bytes :: BotanStructT -> MBA# CSize -> IO CInt Source #
botan_mp_num_bits :: BotanStructT -> MBA# CSize -> IO CInt Source #
hs_botan_mp_to_hex :: BotanStructT -> MBA# Word8 -> Int -> IO CInt Source #
hs_botan_mp_to_dec :: BotanStructT -> MBA# Word8 -> Int -> IO Int Source #
hs_botan_mp_set_from_hex :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_mp_set_from_dec :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_mp_to_bin :: BotanStructT -> MBA# Word8 -> Int -> IO CInt Source #
hs_botan_mp_from_bin :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_mp_flip_sign :: BotanStructT -> IO CInt Source #
botan_mp_add :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_sub :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_mul :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_div :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_mod_mul :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_equal :: BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_is_zero :: BotanStructT -> IO CInt Source #
botan_mp_is_odd :: BotanStructT -> IO CInt Source #
botan_mp_is_even :: BotanStructT -> IO CInt Source #
botan_mp_to_uint32 :: BotanStructT -> MBA# Word32 -> IO CInt Source #
botan_mp_cmp :: MBA# CInt -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_swap :: BotanStructT -> BotanStructT -> IO () Source #
botan_mp_powmod :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_lshift :: BotanStructT -> BotanStructT -> CSize -> IO CInt Source #
botan_mp_rshift :: BotanStructT -> BotanStructT -> CSize -> IO CInt Source #
botan_mp_mod_inverse :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_rand_bits :: BotanStructT -> BotanStructT -> CSize -> IO CInt Source #
botan_mp_rand_range :: BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_gcd :: BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_mp_is_prime :: BotanStructT -> BotanStructT -> CSize -> IO CInt Source #
botan_mp_get_bit :: BotanStructT -> CSize -> IO CInt Source #
botan_mp_set_bit :: BotanStructT -> CSize -> IO CInt Source #
botan_mp_clear_bit :: BotanStructT -> CSize -> IO CInt Source #
botan_block_cipher_init :: MBA# BotanStructT -> BA# Word8 -> IO CInt Source #
botan_block_cipher_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_block_cipher_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt Source #
botan_hash_init :: MBA# BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_hash_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_hash_copy_state :: MBA# BotanStructT -> BotanStructT -> IO CInt Source #
botan_hash_clear :: BotanStructT -> IO CInt Source #
botan_hash_output_length :: BotanStructT -> MBA# CSize -> IO CInt Source #
hs_botan_hash_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_hash_final :: BotanStructT -> MBA# Word8 -> IO CInt Source #
data CipherDirection Source #
Instances
botan_cipher_init :: MBA# BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_cipher_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_cipher_clear :: BotanStructT -> IO CInt Source #
botan_cipher_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt Source #
hs_botan_cipher_start :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_cipher_set_associated_data :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_cipher_get_tag_length :: BotanStructT -> MBA# Int -> IO CInt Source #
hs_botan_cipher_output_size :: BotanStructT -> Int -> IO Int Source #
botan_stream_cipher_init :: MBA# BotanStructT -> BA# Word8 -> IO CInt Source #
botan_stream_cipher_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_stream_cipher_seek :: BotanStructT -> CSize -> IO CInt Source #
botan_stream_cipher_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt Source #
hs_botan_stream_cipher_set_iv :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_kdf :: BA# Word8 -> Ptr Word8 -> CSize -> Ptr Word8 -> CSize -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_bcrypt_generate :: MBA# Word8 -> MBA# CSize -> BA# Word8 -> BotanStructT -> Int -> Word32 -> IO CInt Source #
botan_mac_init :: MBA# BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_mac_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_mac_output_length :: BotanStructT -> MBA# CSize -> IO CInt Source #
botan_mac_final :: BotanStructT -> MBA# Word8 -> IO CInt Source #
botan_mac_set_key :: BotanStructT -> Ptr Word8 -> CSize -> IO CInt Source #
hs_botan_mac_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_mac_clear :: BotanStructT -> IO CInt Source #
hs_botan_mac_name :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
:: Ptr BotanStructT | botan_privkey_t* key |
-> Ptr Word8 | const char* algo_name |
-> Ptr Word8 | const char* algo_params |
-> BotanStructT | botan_rng_t rng |
-> IO CInt |
hs_botan_privkey_load :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> BA# Word8 -> IO CInt Source #
botan_privkey_get_field Source #
:: BotanStructT | botan_mp_t output |
-> BotanStructT | botan_privkey_t key |
-> BA# Word8 | const char* field_name |
-> IO CInt |
botan_privkey_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_privkey_algo_name :: BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt Source #
botan_pubkey_algo_name :: BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt Source #
botan_pubkey_fingerprint :: BotanStructT -> BA# Word8 -> MBA# Word8 -> MBA# CSize -> IO CInt Source #
botan_pubkey_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_pubkey_get_field :: BotanStructT -> BotanStructT -> BA# Word8 -> IO CInt Source #
botan_privkey_load_rsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_pubkey_load_rsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_privkey_load_dsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_pubkey_load_dsa :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_privkey_load_elgamal :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_pubkey_load_elgamal :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_privkey_load_dh :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_pubkey_load_dh :: MBA# BotanStructT -> BotanStructT -> BotanStructT -> BotanStructT -> IO CInt Source #
botan_pk_op_encrypt_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_pk_op_encrypt_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_pk_op_encrypt_output_length :: BotanStructT -> CSize -> MBA# CSize -> IO CInt Source #
hs_botan_pk_op_encrypt :: BotanStructT -> BotanStructT -> MBA# Word8 -> MBA# CSize -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_pk_op_decrypt_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_pk_op_decrypt_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_pk_op_decrypt_output_length :: BotanStructT -> CSize -> MBA# CSize -> IO CInt Source #
hs_botan_pk_op_decrypt :: BotanStructT -> MBA# Word8 -> MBA# CSize -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_pk_op_sign_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_pk_op_sign_output_length :: BotanStructT -> MBA# CSize -> IO CInt Source #
hs_botan_pk_op_sign_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_pk_op_sign_finish :: BotanStructT -> BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt Source #
botan_pk_op_sign_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_pk_op_verify_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_pk_op_verify_destroy :: FunPtr (BotanStructT -> IO ()) Source #
hs_botan_pk_op_verify_update :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_pk_op_verify_finish :: BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_pk_op_key_agreement_create :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Word32 -> IO CInt Source #
botan_pk_op_key_agreement_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_pk_op_key_agreement_export_public :: BotanStructT -> MBA# Word8 -> MBA# CSize -> IO CInt Source #
botan_pk_op_key_agreement_size :: BotanStructT -> MBA# CSize -> IO CInt Source #
hs_botan_pk_op_key_agreement :: BotanStructT -> Ptr Word8 -> CSize -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> Int -> IO CInt Source #
type KeyUsageConstraint = CUInt Source #
Certificate key usage constraints.
pattern NO_CONSTRAINTS :: KeyUsageConstraint Source #
pattern DIGITAL_SIGNATURE :: KeyUsageConstraint Source #
pattern NON_REPUDIATION :: KeyUsageConstraint Source #
pattern KEY_ENCIPHERMENT :: KeyUsageConstraint Source #
pattern DATA_ENCIPHERMENT :: KeyUsageConstraint Source #
pattern KEY_AGREEMENT :: KeyUsageConstraint Source #
pattern KEY_CERT_SIGN :: KeyUsageConstraint Source #
pattern CRL_SIGN :: KeyUsageConstraint Source #
pattern ENCIPHER_ONLY :: KeyUsageConstraint Source #
pattern DECIPHER_ONLY :: KeyUsageConstraint Source #
botan_x509_cert_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_x509_cert_load_file :: MBA# BotanStructT -> BA# Word8 -> IO CInt Source #
botan_x509_cert_dup :: MBA# BotanStructT -> BotanStructT -> IO CInt Source #
botan_x509_cert_get_time_starts :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_time_expires :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_not_before :: BotanStructT -> MBA# Word64 -> IO CInt Source #
botan_x509_cert_not_after :: BotanStructT -> MBA# Word64 -> IO CInt Source #
botan_x509_cert_get_fingerprint :: BotanStructT -> BA# Word8 -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_serial_number :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_authority_key_id :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_subject_key_id :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_public_key_bits :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_issuer_dn :: BotanStructT -> BA# Word8 -> Int -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_get_subject_dn :: BotanStructT -> BA# Word8 -> Int -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_to_string :: BotanStructT -> MBA# Word8 -> MBA# Int -> IO CInt Source #
botan_x509_cert_allowed_usage :: BotanStructT -> CUInt -> IO CInt Source #
hs_botan_x509_cert_verify :: BotanStructT -> BA# BotanStructT -> Int -> BA# BotanStructT -> Int -> Int -> BA# Word8 -> Word64 -> IO CInt Source #
hs_botan_x509_cert_verify_with_crl :: BotanStructT -> BA# BotanStructT -> Int -> BA# BotanStructT -> Int -> BA# BotanStructT -> Int -> Int -> BA# Word8 -> Word64 -> IO CInt Source #
hs_botan_x509_cert_verify_with_certstore_crl :: BotanStructT -> BA# BotanStructT -> Int -> BotanStructT -> BA# BotanStructT -> Int -> Int -> BA# Word8 -> Word64 -> IO CInt Source #
botan_x509_crl_load_file :: MBA# BotanStructT -> BA# Word8 -> IO CInt Source #
botan_x509_crl_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_x509_is_revoked :: BotanStructT -> BotanStructT -> IO CInt Source #
botan_x509_certstore_load_file :: MBA# BotanStructT -> BA# Word8 -> IO CInt Source #
botan_x509_certstore_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_key_wrap3394 :: Ptr Word8 -> CSize -> Ptr Word8 -> CSize -> MBA# Word8 -> MBA# CSize -> IO CInt Source #
hs_botan_key_unwrap3394 :: BA# Word8 -> Int -> Int -> Ptr Word8 -> CSize -> Ptr Word8 -> CSize -> IO CInt Source #
hs_botan_hotp_init :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> IO CInt Source #
botan_hotp_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_hotp_generate :: BotanStructT -> MBA# Word32 -> Word64 -> IO CInt Source #
hs_botan_totp_init :: MBA# BotanStructT -> BA# Word8 -> Int -> Int -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_totp_destroy :: FunPtr (BotanStructT -> IO ()) Source #
botan_totp_generate :: BotanStructT -> MBA# Word32 -> Word64 -> IO CInt Source #
botan_totp_check :: BotanStructT -> Word32 -> Word64 -> CSize -> IO CInt Source #
hs_botan_fpe_fe1_init :: MBA# BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> Int -> Word32 -> IO CInt Source #
hs_botan_fpe_encrypt :: BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
hs_botan_fpe_decrypt :: BotanStructT -> BotanStructT -> BA# Word8 -> Int -> Int -> IO CInt Source #
botan_fpe_destroy :: FunPtr (BotanStructT -> IO ()) Source #