• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
      • Vwsim
      • Isar
      • Wp-gen
      • Dimacs-reader
      • Pfcs
      • Legacy-defrstobj
      • Proof-checker-array
      • Soft
      • C
      • Farray
      • Rp-rewriter
      • Instant-runoff-voting
      • Imp-language
      • Sidekick
      • Leftist-trees
      • Java
      • Taspi
      • Bitcoin
      • Riscv
      • Des
      • Ethereum
      • X86isa
      • Sha-2
      • Yul
      • Zcash
      • Proof-checker-itp13
      • Regex
      • ACL2-programming-language
      • Json
      • Jfkr
      • Equational
      • Cryptography
        • R1cs
        • Interfaces
          • Definterface-hmac
          • Definterface-encrypt-block
          • Definterface-hash
          • Definterface-encrypt-init
          • Definterface-pbkdf2
          • Aes-256-cbc-pkcs7-interface
          • Aes-192-cbc-pkcs7-interface
          • Aes-128-cbc-pkcs7-interface
          • Aes-256-interface
          • Aes-192-interface
          • Aes-128-interface
          • Pbkdf2-hmac-sha-512-interface
          • Keccak-256-interface
          • Sha-256-interface
          • Keccak-512-interface
          • Ripemd-160-interface
          • Sha-512-interface
            • Pbkdf2-hmac-sha-256-interface
            • Hmac-sha-512-interface
            • Hmac-sha-256-interface
            • Secp256k1-interface
            • Secp256k1-ecdsa-interface
          • Sha-2
          • Keccak
          • Kdf
          • Mimc
          • Padding
          • Hmac
          • Elliptic-curves
          • Attachments
          • Elliptic-curve-digital-signature-algorithm
        • Poseidon
        • Where-do-i-place-my-book
        • Axe
        • Bigmems
        • Builtins
        • Execloader
        • Aleo
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Interfaces

    Sha-512-interface

    SHA-512 interface.

    SHA-512 is specified in the FIPS PUB 180-4 standard.

    According to FIPS PUB 180-4, the input of SHA-512 is a sequence of less than 2^{128} bits, or less than 2^{125} bytes.

    According to FIPS PUB 180-4, the output of SHA-512 is a sequence of exactly 512 bits, or 64 bytes.

    See also:

    • SHA-512 executable specification

    Definitions and Theorems

    Theorem: bit-list-of-sha-512-bits

    (defthm bit-list-of-sha-512-bits
      (bit-listp (sha-512-bits bits)))

    Theorem: byte-list-of-sha-512-bytes

    (defthm byte-list-of-sha-512-bytes
      (byte-listp (sha-512-bytes bytes)))

    Theorem: len-of-sha-512-bits

    (defthm len-of-sha-512-bits
      (equal (len (sha-512-bits bits)) 512))

    Theorem: len-of-sha-512-bytes

    (defthm len-of-sha-512-bytes
      (equal (len (sha-512-bytes bytes)) 64))

    Theorem: sha-512-bits-of-bit-list-fix-bits

    (defthm sha-512-bits-of-bit-list-fix-bits
      (equal (sha-512-bits (acl2::bit-list-fix bits))
             (sha-512-bits bits)))

    Theorem: sha-512-bits-bit-list-equiv-congruence-on-bits

    (defthm sha-512-bits-bit-list-equiv-congruence-on-bits
      (implies (acl2::bit-list-equiv bits bits-equiv)
               (equal (sha-512-bits bits)
                      (sha-512-bits bits-equiv)))
      :rule-classes :congruence)

    Theorem: sha-512-bytes-of-byte-list-fix-bytes

    (defthm sha-512-bytes-of-byte-list-fix-bytes
      (equal (sha-512-bytes (byte-list-fix bytes))
             (sha-512-bytes bytes)))

    Theorem: sha-512-bytes-byte-list-equiv-congruence-on-bytes

    (defthm sha-512-bytes-byte-list-equiv-congruence-on-bytes
      (implies (byte-list-equiv bytes bytes-equiv)
               (equal (sha-512-bytes bytes)
                      (sha-512-bytes bytes-equiv)))
      :rule-classes :congruence)

    Theorem: true-listp-of-sha-512-bits

    (defthm true-listp-of-sha-512-bits
      (true-listp (sha-512-bits bits))
      :rule-classes :type-prescription)

    Theorem: true-listp-of-sha-512-bytes

    (defthm true-listp-of-sha-512-bytes
      (true-listp (sha-512-bytes bytes))
      :rule-classes :type-prescription)

    Theorem: consp-of-sha-512-bits

    (defthm consp-of-sha-512-bits
      (consp (sha-512-bits bits))
      :rule-classes :type-prescription)

    Theorem: consp-of-sha-512-bytes

    (defthm consp-of-sha-512-bytes
      (consp (sha-512-bytes bytes))
      :rule-classes :type-prescription)

    Theorem: byte-list64p-of-sha-512-bytes

    (defthm byte-list64p-of-sha-512-bytes
      (byte-list64p (sha-512-bytes bytes)))