[BACK]Return to crypto.html CVS log [TXT][DIR] Up to [local] / www

File: [local] / www / crypto.html (download) (as text)

Revision 1.30, Thu Feb 11 04:54:11 1999 UTC (25 years, 3 months ago) by todd
Branch: MAIN
Changes since 1.29: +1 -2 lines

remove duplication

<!DOCTYPE HTML PUBLIC  "-//IETF//DTD HTML Strict Level 2//EN//2.0">
<html>
<head>
<title>Cryptography in OpenBSD</title>
<link rev=made href=mailto:www@openbsd.org>
<meta name="resource-type" content="document">
<meta name="description" content="OpenBSD cryptography">
<meta name="keywords" content="openbsd,cryptography">
<meta name="distribution" content="global">
<meta name="copyright" content="This document copyright 1997 by OpenBSD.">
</head>

<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#23238E">

<img alt="[OpenBSD]" height=200 width=200 SRC="images/blowfish.jpg">

<p>
<h3><font color=#e00000><strong>OpenBSD Cryptography</strong></font></h3>
The OpenBSD project is based in Canada.<p>

The <a href=ECL.html>Export Control List of Canada</a>
places no significant restriction on the export of
cryptographic software, and is even more explicit about the free
export of freely-available cryptographic software.  Marc Plumb has
done
<a href=http://insight.mcmaster.ca/org/efc/pages/doc/crypto-export.html>
some research to test the cryptographic laws.</a>
<p>

Hence the OpenBSD project has embedded cryptography into numerous places
in the operating system.  We require that the cryptographic software we
use be <a href=policy.html>freely available and with good licenses</a>.
We do not use cryptography with nasty patents.
We also require that such software is from countries with useful export
licenses because we do not wish to break the laws of any country.
The cryptographic software components which we use currently were
written in Argentina, Australia, Canada, Germany, Greece, Norway, and
Sweden.
<p>

When we create OpenBSD releases or snapshots we build our release
binaries in free countries to assure that the sources and binaries we
provide to users are free of tainting.  In the past our release binary
builds have been done in Canada, Sweden, and Germany.<p>

OpenBSD ships with Kerberos IV included.  The codebase we use is the
exportable KTH-based release from Sweden.  Our X11 source has been
extended to make use of Kerberos IV as well.  Kerberos V support will
perhaps appear in 1999, but at present time a freely exportable
Kerberos V release does not exist.<p>

Today cryptography is an important means for enhancing the <a
href=security.html>security</a> of an operating system.  The
cryptography utilized in OpenBSD can be classified into three
different aspects:<p>

<ul>
<li><a href=#prng>Pseudo Random Number Generators</a> (PRNG): ARC4, ...
<li><a href=#hash>Cryptographic Hash Functions</a>: MD5, SHA1, ...
<li><a href=#trans>Cryptographic Transforms</a>: DES, Blowfish, ...
</ul>

<p>
<a name=prng></a>
<h3><font color=#e00000><strong>Pseudo Random Number Generators</strong></font></h3>
A Pseudo Random Number Generator (PRNG) provides applications with a stream of 
numbers which have certain important properties for system security:<p>

<ul>
<li>It should be impossible for an outsider to predict the output of the
	random number generator even with knowledge of previous output.
<li>The generated numbers should not have repeating patterns which means
	the PRNG should have a very long cycle length.
</ul>

A PRNG is normally just an algorithm where the same initial starting
values will yield the same sequence of outputs. On a multiuser
operating system there are many sources which allow seeding the PRNG
with random data. The OpenBSD kernel uses the mouse interrupt timing,
network data interrupt latency, inter-keypress timing and disk IO
information to fill an entropy pool.  Random numbers are available for
kernel routines and are exported via devices to userland programs.
So far random numbers are used in the following places<p>

<ul>
<li>Dynamic sin_port allocation in bind(2).
<li>PIDs of processes.
<li>IP datagram IDs.
<li>RPC transaction IDs (XID).
<li>NFS RPC transaction IDs (XID).
<li>DNS Query-IDs.
<li>Inode generation numbers, see getfh(2) and fsirand(8).
<li>Timing perturbance in traceroute(1).
<li>Stronger temporary names for mktemp(3) and mkstemp(3)
<li>Randomness added to the TCP ISS value for protection against
	spoofing attacks.
<li>random padding in IPSEC esp_old packets.
<li>To generate salts for the various password algorithms.
<li>For generating fake S/Key challenges.
<li>In <a href=http://wserver.physnet.uni-hamburg.de/provos/photuris/>photurisd</a> 
        and <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=isakmpd>isakmpd</a>
	to provide liveness proof of key exchanges.
</ul>

<p>
<a name=hash></a>
<h3><font color=#e00000><strong>Cryptographic Hash Functions</strong></font></h3>
A Hash Function compresses its input data to a string of
constant size. For a Cryptographic Hash Function it is infeasible to find
<ul>
<li>two inputs which have the same output (collision resistant),
<li>a different input for a given input with the same output
	(2nd preimage resistant).
</ul>

In OpenBSD MD5, SHA1, and RIPEMD-160 are used as Cryptographic Hash Functions,
e.g.
<ul> 
<li>In <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=skey>S/Key</a>
    to provide one time passwords.
<li>In <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=ipsec>IPsec</a>,
    <a href=http://wserver.physnet.uni-hamburg.de/provos/photuris/>photurisd</a>
    and
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=isakmpd>isakmpd(8)</a>
    to authenticate the data origin of packets and to ensure packet integrity.
<li>For FreeBSD-style MD5 passwords (not enabled by default), see
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=passwd.conf&sektion=5>
    passwd.conf(5)</a>
<li>For TCP SYN cookie support (not enabled by default), see
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=options&sektion=4>
    options(4)</a>
<li>In libssl for digital signing of messages.
</ul>

<p>
<a name=trans></a>
<h3><font color=#e00000><strong>Cryptographic Transforms</strong></font></h3>
Cryptographic Transforms are used to encrypt and decrypt data. These
are normally used with an encryption key for data encryption and with
a decryption key for data decryption. The security of a Cryptographic
Transform should rely only on the keying material.<p>

OpenBSD provides transforms like DES, 3DES, Blowfish and Cast for the
kernel and userland programs, which are used in many places like
<ul>
<li>In libc for creating
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=blf_key>Blowfish</a>
    passwords.
<li>In
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=ipsec>IPsec</a>
    to provide confidentiality for the network layer.
<li>In Kerberos and a handful of kerberized applications, like
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=telnet>telnet</a>,
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=cvs>cvs</a>,
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=rsh>rsh</a>,
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=rcp>rcp</a>,
    and
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=rlogin>rlogin</a>.
<li>In <a href=http://wserver.physnet.uni-hamburg.de/provos/photuris/>
    photurisd</a> and
    <a href=http://www.openbsd.org/cgi-bin/man.cgi?query=isakmpd>isakmpd</a>
    to protect the exchanges where IPsec key material is negotiated.
<li>In AFS to protect the messages passing over the network, providing
    confidentiality of remote filesystem access.
<li>In libssl to let applications communicate over the de-facto standard
	cryptographically secure SSL protocol.
</ul>

<p>
<hr>
<a href=/index.html><img height=24 width=24 src=back.gif border=0 alt=OpenBSD></a>
<a href=mailto:www@openbsd.org>www@openbsd.org</a>
<br>
<small>$OpenBSD: crypto.html,v 1.30 1999/02/11 04:54:11 todd Exp $</small>

</body>
</html>