Sum (Unix)
   HOME





Sum (Unix)
is a legacy utility available on some Unix and Unix-like operating systems. This utility outputs a 16-bit checksum of each argument file, as well as the number of blocks they take on disk. — manual pages from GNU coreutils Two different checksum algorithms are in use. POSIX abandoned sum in favor of cksum. Overview The program is generally only useful for historical interest. It is not part of POSIX. Two algorithms are typically available: a BSD checksum and a SYSV checksum. Both are weaker than the already weak 32-bit CRC used by cksum. The default algorithm on FreeBSD and GNU implementations is the BSD checksum. Switching between the two algorithms is done via command line options. The two commonly used algorithms are as follows. The BSD sum, -r in GNU sum and -o1 in FreeBSD cksum: * Initialize checksum to 0 * For each byte of the input stream ** Perform 16-bit bitwise right rotation by 1 bit on the checksum ** Add the byte to the checksum, and apply modulo 2 ^ 16 to ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


picture info

Ken Thompson
Kenneth Lane Thompson (born February 4, 1943) is an American pioneer of computer science. Thompson worked at Bell Labs for most of his career where he designed and implemented the original Unix operating system. He also invented the B (programming language), B programming language, the direct predecessor to the C (programming language), C language, and was one of the creators and early developers of the Plan 9 from Bell Labs, Plan 9 operating system. Since 2006, Thompson has worked at Google, where he co-developed the Go (programming language), Go language. A recipient of the Turing award, he is considered one of the greatest computer programmers of all time. Other notable contributions included his work on regular expressions and early computer text editors QED (text editor), QED and ed (text editor), ed, the definition of the UTF-8 encoding, and his work on computer chess that included the creation of endgame tablebases and the chess machine Belle (chess machine), Belle. He won ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


Cksum
cksum is a command in Unix and Unix-like operating systems that generates a checksum value for a file or stream of data. The cksum command reads each file given in its arguments, or standard input if no arguments are provided, and outputs the file's 32-bit cyclic redundancy check (CRC) checksum and byte count. The CRC output by cksum is different from the CRC-32 used in zip, PNG and zlib. The cksum command can be used to verify that files transferred by unreliable means arrived intact. However, the CRC checksum calculated by the cksum command is not cryptographically secure: While it guards against ''accidental'' corruption (it is unlikely that the corrupted data will have the same checksum as the intended data), it is not difficult for an attacker to ''deliberately'' corrupt the file in a specific way that its checksum is unchanged. Unix-like systems typically include other commands for cryptographically secure checksums, such as sha256sum. The command is available as a separa ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


picture info

Unix Package Management-related Software
Unix (, ; trademarked as UNIX) is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and others. Initially intended for use inside the Bell System, AT&T licensed Unix to outside parties in the late 1970s, leading to a variety of both academic and commercial Unix variants from vendors including University of California, Berkeley (BSD), Microsoft (Xenix), Sun Microsystems (SunOS/Solaris), HP/ HPE (HP-UX), and IBM (AIX). The early versions of Unix—which are retrospectively referred to as "Research Unix"—ran on computers such as the PDP-11 and VAX; Unix was commonly used on minicomputers and mainframes from the 1970s onwards. It distinguished itself from its predecessors as the first portable operating system: almost the entire operating system is written in the C programming language (in 1973), which allows Unix to operate ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


picture info

Linux Package Management-related Software
Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically packaged as a Linux distribution (distro), which includes the kernel and supporting system software and libraries—most of which are provided by third parties—to create a complete operating system, designed as a clone of Unix and released under the copyleft GPL license. Thousands of Linux distributions exist, many based directly or indirectly on other distributions; popular Linux distributions include Debian, Fedora Linux, Linux Mint, Arch Linux, and Ubuntu, while commercial distributions include Red Hat Enterprise Linux, SUSE Linux Enterprise, and ChromeOS. Linux distributions are frequently used in server platforms. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses and recommends the name "GNU/Linux" to emphasize the use and impo ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


UnxUtils
UnxUtils is a collection of utility programs that provide popular Unix-based shell commands ported from GNU implementations as native Windows programs that depend only on Win32 and the Microsoft C- runtime ( msvcrt.dll). The collection was last updated externally on April 15, 2003, by Karl M. Syring. , the most recent release was an open-source project at SourceForge, with the latest binary release in March, 2007 (though the files are dated 2000). The independent distribution included a main zip archive (UnxUtils.zip, 3,365,638 bytes) complemented by more recent updates (UnxUpdates.zip, 878,847 bytes, brought some binaries up to year 2003), but the SourceForge project has no UnxUpdates.zip package. An alternative collection of Unix-based utilities for Windows is GnuWin32. It has later versions of many programs, but requires supporting files (e.g. DLLs). Supported commands include: * agrep *ansi2knr * basename * bc *bison *bunzip2 *bzip2 *bzip2recover * cat *chgrp *chm ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


GNU Core Utilities
The GNU Core Utilities or coreutils is a collection of GNU software that implements many standard, Unix-based shell commands. The utilities generally provide POSIX compliant interface when the environment variable is set, but otherwise offers a superset to the standard interface. For example, the utilities support long options and options after parameters. This environment variable enables a different functionality in BSD. Similar collections are available in the FOSS ecosystem, with a slightly different scope and focus (less functionality), or license. For example, BusyBox which is licensed under GPL-2.0-only, and Toybox which is licensed under 0BSD. Commands The commands implemented by coreutils are listed below. Throughout this article and customary for Unix-based systems, the term ''file'' refers to all file system items including regular files and special files such as directories. File utilities * chcon Changes file security context ( SELinux) * chgrp Chan ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


picture info

Standard Input
In computer programming, standard streams are preconnected input and output communication channels between a computer program and its environment when it begins execution. The three input/output (I/O) connections are called standard input (stdin), standard output (stdout) and standard error (stderr). Originally I/O happened via a physically connected system console (input via keyboard, output via monitor), but standard streams abstract this. When a command is executed via an interactive shell, the streams are typically connected to the text terminal on which the shell is running, but can be changed with redirection or a pipeline. More generally, a child process inherits the standard streams of its parent process. Application Users generally know standard streams as input and output channels that handle data coming from an input device, or that write data from the application. The data may be text with any encoding, or binary data. When a program is run as a daemon, its standard ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


picture info

Command-line Interface
A command-line interface (CLI) is a means of interacting with software via command (computing), commands each formatted as a line of text. Command-line interfaces emerged in the mid-1960s, on computer terminals, as an interactive and more user-friendly alternative to the non-interactive mode available with punched cards. For a long time, a CLI was the most common interface for software, but today a graphical user interface (GUI) is more common. Nonetheless, many programs such as operating system and software development utility software, utilities still provide CLI. A CLI enables automation, automating computer program, programs since commands can be stored in a scripting language, script computer file, file that can be used repeatedly. A script allows its contained commands to be executed as group; as a program; as a command. A CLI is made possible by command-line interpreters or command-line processors, which are programs that execute input commands. Alternatives to a CLI ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


picture info

Seventh Edition Unix
Version 7 Unix, also called Seventh Edition Unix, Version 7 or just V7, was an important early release of the Unix operating system. V7, released in 1979, was the last Bell Laboratories release to see widespread distribution before the commercialization of Unix by AT&T Corporation in the early 1980s. V7 was originally developed for Digital Equipment Corporation's PDP-11 minicomputers and was later ported to other platforms. Overview Unix versions from Bell Labs were designated by the edition of the user's manual with which they were accompanied. Released in 1979, the Seventh Edition was preceded by Sixth Edition, which was the first version licensed to commercial users. Development of the Research Unix line continued with the Eighth Edition, which incorporated development from 4.1BSD, through the Tenth Edition, after which the Bell Labs researchers concentrated on developing Plan 9. V7 was the first readily portable version of Unix. As this was the era of minicomputers, wit ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  




Default (computer Science)
A default, in computer science, refers to the preexisting value of a user-configurable setting that is assigned to a software application, computer program or device. Such settings are also called factory settings, or factory presets, especially for electronic devices. Default values are standards values that are universal to all instances of the device or model and intended to make the device as accessible as possible "out of the box" without necessitating a lengthy configuration process prior to use. The user only has to modify the default settings according to their personal preferences. In many devices, the user has the option to restore these default settings for one or all options. Such an assignment makes the choice of that setting or value more likely, this is called the default effect. Examples Application software preferences One use of default parameters is for initial settings for application software. For example, the first time a user runs an application it may ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


SYSV Checksum
The SYSV checksum algorithm was a commonly used, legacy checksum algorithm. It has been implemented in UNIX System V and is also available through the sum command line utility. This algorithm is useless on a security perspective, and is weaker than the CRC-32 cksum for error detection. — manual pages from GNU coreutils The GNU Core Utilities or coreutils is a collection of GNU software that implements many standard, Unix-based shell commands. The utilities generally provide POSIX compliant interface when the environment variable is set, but otherwise offers ... Description of the algorithm The main part of this algorithm is simply adding up all bytes in a 32-bit sum. As a result, this algorithm has the characteristics of a simple sum: * re-arranging the same bytes in another order (e.g. moving text from one place to another place) does not change the checksum. * increasing one byte and decreasing another byte by the same amount does not change the checksum. * adding or r ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]  


BSD Checksum
The BSD checksum algorithm was a commonly used, legacy checksum algorithm. It has been implemented in old BSD and is also available through the sum command line utility. This algorithm is useless from a security perspective, and is weaker than the CRC-32 cksum for error detection. — manual pages from GNU coreutils Computation of the BSD checksum Below is the relevant part of the GNU sum source code ( GPL licensed). It computes a 16-bit checksum by adding up all bytes (8-bit words) of the input data stream. In order to avoid many of the weaknesses of simply adding the data, the checksum accumulator is circular rotated to the right by one bit at each step before the new char is added. int bsdChecksumFromFile(FILE *fp) /* The file handle for input data */ Description of the algorithm As mentioned above, this algorithm computes a checksum by segmenting the data and adding it to an accumulator that is circular right shifted between each summation. To keep the accumulator within ...
[...More Info...]      
[...Related Items...]     OR:     [Wikipedia]   [Google]   [Baidu]