summaryrefslogtreecommitdiffstats
path: root/sys/geom/bde/g_bde_crypt.c
Commit message (Collapse)AuthorAgeFilesLines
* Comment typophk2005-07-201-1/+1
|
* stop including rijndael-api-fst.h from rijndael.h.ume2005-03-111-1/+1
| | | | this is required to integrate opencrypto into crypto.
* /* -> /*- for copyright notices, minor format tweaks as necessaryimp2005-01-061-2/+2
|
* Fix a problem that shows up if less than the full complement ofphk2004-09-111-1/+1
| | | | | lock sectors are defined ("number_of_keys" argument to gbde init being less than 4 in the default compile).
* Remove the MD5_KEY debugging toolphk2004-01-231-33/+0
|
* Correct bzero length so we clear the entire key structure.phk2003-09-081-1/+1
|
* Bzero the right number of bytes.phk2003-09-061-1/+1
| | | | Found by: Juergen Buchmueller <pullmoll@stop1984.com>
* Don't use & in front of arrays.phk2003-05-311-2/+2
| | | | Found by: FlexeLint
* Considering that I did cast the arguments to (intmax_t) I must havephk2003-05-021-4/+4
| | | | been sleepy since I used %qd instead of %jd.
* Fix an obscure fencepost error in GBDE's sector mapping code:phk2003-04-291-0/+26
| | | | | | | | | | | | | | | For certain combinations of sectorsize, mediasize and random numbers (used to define the mapping), a multisector read or write would ignore some subset of the sectors past the first sector in the request because those sectors would be mapped past the end of the parent device, and normal "end of media" truncation would zap that part of the request. Rev 1.19+1.20 of g_bde_work.c added the check which should have alerted me to this happening. This commit maps the request correctly and adds KASSERTS to make sure things stay inside the parent device. This does not change the on-disk layout of GBDE, there is no need to backup/restore.
* I accidentally leaked this debugging tool in with my last commit.phk2003-04-281-2/+4
| | | | Disable it with a direct warning.
* Rename g_bde_get_sector() to g_bde_get_keysector() and pick up thephk2003-04-281-0/+35
| | | | offset from the work packet.
* Use sys/endian.h instead of geom_enc.c for endian-agnostfication.phk2003-04-031-1/+2
|
* Including <sys/stdint.h> is (almost?) universally only to be able to usephk2003-03-181-1/+0
| | | | | %j in printfs, so put a newsted include in <sys/systm.h> where the printf prototype lives and save everybody else the trouble.
* Limit our requests to DFLTPHYS, this is generally a good idea forphk2003-03-071-0/+5
| | | | | | memory-allocation purposes. Right now it is also a very good idea because we hit a Giant assertion in the free(9) processing if we free something larger than 64k.
* Optimize the size of the work-items by letting the mapping functionphk2003-01-021-38/+55
| | | | | decide the largest size which stays inside the zone and does not collide with a lock sector.
* Solve another bug in the mapping code: correctly skip lock sectors.phk2002-12-181-2/+2
| | | | | | | | | Make sure sector zero is protected if it contains metadata. Lower WARNS for gbde to 3 on non-i386 archs. rijndael-fst is evil but appearntly does the right thing and passes the test-vectors. MFC Candidate.
* Fix two blunders in the mapping functions which can lead to corrupt data,phk2002-12-181-2/+2
| | | | | | | | for request sizes larger than the sectorsize or for multi-key setups. See warning mailed to current@ for details of recovery. Found by: Marcus Reid <marcus@blazingdot.com>
* Conceiveably, there may exist an algorithm which can tell if a sequence of bytesphk2002-12-011-0/+7
| | | | | | | | are the output of AES/128/CBC or ARC4RANDOM. Encrypt the random data with which we wipe when we get a BIO_DELETE to make such an algorithm useful. Sponsored by: DARPA & NAI Labs Approved by: re (blanket)
* Run a revision on the GBDE encryption facility.phk2002-11-041-47/+10
| | | | | | | | | | | | | | | | | | | | Replace ARC4 with SHA2-512. Change lock-structure encoding to use random ordering rather for obscurity. Encrypt lock-structure with AES/256 instead of AES/128. Change kkey derivation to be MD5 hash based. Watch for malloc(M_NOWAIT) failures and ditch our cache when they happen. Remove clause 3 of the license with NAI Labs consent. Many thanks to "Lucky Green" <shamrock@cypherpunks.to> and "David Wagner" <daw@cs.berkeley.edu>, for code reading, inputs and suggestions. This code has still not been stared at for 10 years by a gang of hard-core cryptographers. Discretion advised. NB: These changes result in the on-disk format changing: dump/restore needed. Sponsored by: DARPA & NAI Labs.
* Change the kkey generation cherry-picker to use MD5.phk2002-10-301-36/+17
| | | | Sponsored by: DARPA & NAI Labs
* Fix a bug in the cherry-picker kkey generator routine.phk2002-10-281-0/+1
| | | | | | | WARNING: You need to backup and restore the _unencrypted_ contents WARNING: of your GBDE disks when you take this update! Sponsored by: DARPA & NAI Labs.
* Add Geom Based Disk Encryption to the tree.phk2002-10-191-0/+356
This is an encryption module designed for to secure denial of access to the contents of "cold disks" with or without destruction activation. Major features: * Based on AES, MD5 and ARC4 algorithms. * Four cryptographic barriers: 1) Pass-phrase encrypts the master key. 2) Pass-phrase + Lock data locates master key. 3) 128 bit key derived from 2048 bit master key protects sector key. 3) 128 bit random single-use sector keys protect data payload. * Up to four different changeable pass-phrases. * Blackening feature for provable destruction of master key material. * Isotropic disk contents offers no information about sector contents. * Configurable destination sector range allows steganographic deployment. This commit adds the kernel part, separate commits will follow for the userland utility and documentation. This software was developed for the FreeBSD Project by Poul-Henning Kamp and NAI Labs, the Security Research Division of Network Associates, Inc. under DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), as part of the DARPA CHATS research program. Many thanks to Robert Watson, CBOSS Principal Investigator for making this possible. Sponsored by: DARPA & NAI Labs.
OpenPOWER on IntegriCloud