词条 | Sha1sum |
释义 |
{{mono|sha1sum}} is a computer program that calculates and verifies SHA-1 hashes. It is commonly used to verify the integrity of files. It (or a variant) is installed by default in most Unix-like operating systems.{{Citation needed|reason=A quick survey shows that only Linux variants seem to ship this program by default.|date=February 2017}} Variants include {{mono|shasum}} (which permits SHA-1 through SHA-512 hash functions to be selected manually), {{mono|sha224sum}}, {{mono|sha256sum}}, {{mono|sha384sum}} and {{mono|sha512sum}}, which use a specific SHA-2 hash function, and {{mono|sha3sum}} (which permits SHA-3 through SHA3-512, SHAKE, RawSHAKE and Keccak functions to be selected manually). Versions for Microsoft Windows also exist, and the ActivePerl distribution includes a perl implementation of shasum. On FreeBSD and OpenBSD the utilities are called md5, sha1, sha256, sha512. These versions offer slightly different options and features. Additionally, FreeBSD offers the "SKEIN" family of message digests. The SHA-1 variants are proven vulnerable to collision attacks, and users should use for example a SHA-2 variant such as sha256sum instead to prevent tampering by an adversary.[1][2] It is included in GNU Core Utilities,[3] Busybox[4] and Toybox.[5] ExamplesTo create a file with an sha1 hash in it, if one is not provided: If distributing one file, ".sha1" may be appended to the filename e.g.: The output contains one line per file of the form " To verify the file was downloaded correctly: Hash file treessha1sum can only create checksums of one or multiple files inside a directory, but not of a directory tree, i.e. of subdirectories, sub-subdirectories, etc. and the files they contain. This is possible by using sha1sum in combination with the commands find and xargs (and optionally with sort so that the files are sorted in the checksum file). sha1deep can create checksums of a directory tree. You can also use sha1sum with exec: See also
References1. ^{{cite web|url=https://www.schneier.com/blog/archives/2005/02/cryptanalysis_o.html|title=Cryptanalysis of SHA-1|author=Bruce Schneier|publisher=Schneier on Security}} 2. ^https://security.googleblog.com/2017/02/announcing-first-sha1-collision.html 3. ^https://www.gnu.org/software/coreutils/manual/html_node/sha1sum-invocation.html 4. ^https://github.com/mirror/busybox/blob/a6f8651/testsuite/sha1sum.tests 5. ^https://github.com/landley/toybox/blob/409a8e093a4ea8e0892ab302b4fd433d08f435eb/toys/lsb/md5sum.c#L17 External links
2 : Cryptographic software|Unix security-related software |
随便看 |
|
开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。