Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nettle
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
5
Merge Requests
5
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Nettle
nettle
Commits
f6e6b538
Commit
f6e6b538
authored
Nov 11, 2017
by
Niels Möller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update manual
parent
42afc42f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
51 additions
and
33 deletions
+51
-33
ChangeLog
ChangeLog
+8
-0
nettle.texinfo
nettle.texinfo
+43
-33
No files found.
ChangeLog
View file @
f6e6b538
2017-11-11 Niels Möller <nisse@lysator.liu.se>
* nettle.texinfo: Document nettle_get_hashes, nettle_get_ciphers
and nettle_get_aeads, and replace nettle_secp_256r1 by
nettle_get_secp_256r1. Update version numbers. Delete ancient
setting of ispell-skip-region-alist as an emacs file-local
variable.
2017-11-08 Niels Möller <nisse@lysator.liu.se>
* ecc-curve.h (nettle_secp_192r1, nettle_secp_224r1)
...
...
nettle.texinfo
View file @
f6e6b538
...
...
@@ -7,14 +7,14 @@
@syncodeindex fn cp
@c
%**end of header
@set UPDATED-FOR 3.
2
@set UPDATED-FOR 3.
4
@set AUTHOR Niels Möller
@copying
This manual is for the Nettle library (version @value
{
UPDATED-FOR
}
), a
low-level cryptographic library.
Originally written 2001 by @value
{
AUTHOR
}
, updated 201
5
.
Originally written 2001 by @value
{
AUTHOR
}
, updated 201
7
.
@quotation
This manual is placed in the public domain. You may freely copy it, in
...
...
@@ -1009,6 +1009,7 @@ This function also resets the context in the same way as
@subsection The @code
{
struct nettle
_
hash
}
abstraction
@cindex nettle
_
hash
@cindex nettle
_
hashes
@cindex nettle
_
get
_
hashes
Nettle includes a struct including information about the supported hash
functions. It is defined in @file
{
<nettle/nettle-meta.h>
}
, and is used
...
...
@@ -1039,10 +1040,19 @@ These are all the hash functions that Nettle implements.
Nettle also exports a list of all these hashes.
@deftypevr
{
Constant Array
}
{
struct nettle
_
hash **
}
nettle
_
hashes
@deftypefun const struct nettle
_
hash **nettle
_
get
_
hashes(void)
Returns a NULL-terminated list of pointers to supported hash functions.
This list can be used to dynamically enumerate or search the supported
algorithms. NULL-terminated.
@end deftypevr
algorithms.
@end deftypefun
@deffn Macro nettle
_
hashes
A macro expanding to a call to nettle
_
get
_
hashes, so that one could
write, e.g., @code
{
nettle
_
hashes[0]->name
}
for the name of the first
hash function on the list. In earlier versions, this was not a macro but
the actual array of pointers. However, referring directly to the array
makes the array size leak into the ABI in some cases.
@end deffn
@node Cipher functions, Cipher modes, Hash functions, Reference
@comment node-name, next, previous, up
...
...
@@ -1826,6 +1836,7 @@ Analogous to @code{twofish_encrypt}
@subsection The @code
{
struct nettle
_
cipher
}
abstraction
@cindex nettle
_
cipher
@cindex nettle
_
ciphers
@cindex nettle
_
get
_
ciphers
Nettle includes a struct including information about some of the more
regular cipher functions. It can be useful for applications that need a
...
...
@@ -1870,10 +1881,16 @@ ones without weak keys or other oddities.
Nettle also exports a list of all these ciphers without weak keys or
other oddities.
@deftypevr
{
Constant Array
}
{
struct nettle
_
cipher **
}
nettle
_
ciphers
@deftypefun const struct nettle
_
cipher **nettle
_
get
_
ciphers(void)
Returns a NULL-terminated list of pointers to supported block ciphers.
This list can be used to dynamically enumerate or search the supported
algorithms. NULL-terminated.
@end deftypevr
algorithms.
@end deftypefun
@deffn Macro nettle
_
ciphers
A macro expanding to a call to nettle
_
get
_
ciphers. In earlier versions,
this was not a macro but the actual array of pointers.
@end deffn
@node Cipher modes, Authenticated encryption, Cipher functions, Reference
@comment node-name, next, previous, up
...
...
@@ -2975,6 +2992,7 @@ smaller than @code{CHACHA_POLY1305_DIGEST_SIZE}, only the first
@subsection The @code
{
struct nettle
_
aead
}
abstraction
@cindex nettle
_
aead
@cindex nettle
_
aeads
@cindex nettle
_
get
_
aeads
Nettle includes a struct including information about the supported hash
functions. It is defined in @file
{
<nettle/nettle-meta.h>
}
.
...
...
@@ -2998,10 +3016,16 @@ message size is specified in advance makes it incompatible with the
Nettle also exports a list of all these constructions.
@deftypevr
{
Constant Array
}
{
struct nettle
_
aead **
}
nettle
_
aeads
This list can be used to dynamically enumerate or search the supported
algorithms. NULL-terminated.
@end deftypevr
@deftypefun const struct nettle
_
aead **nettle
_
get
_
aeads(void)
Returns a NULL-terminated list of pointers to supported algorithms.This
list can be used to dynamically enumerate or search the supported
algorithms.
@end deftypefun
@deffn Macro nettle
_
aeads
A macro expanding to a call to nettle
_
get
_
aeads. In earlier versions,
this was not a macro but the actual array of pointers.
@end deffn
@node Keyed hash functions, Key derivation functions, Authenticated encryption, Reference
@comment node-name, next, previous, up
...
...
@@ -4337,12 +4361,12 @@ x^3 - 3 x + b @pmod{p}}, i.e., the points have coordinates @math{(x,y)},
both considered as integers modulo a specified prime @math
{
p
}
. Curves
are represented as a @code
{
struct ecc
_
curve
}
. It also supports
curve25519, which uses a different form of curve. Supported curves are
declared in @file
{
<nettle/ecc-curve.h>
}
, e.g.,
@code
{
nettle
_
secp
_
256r1
}
for a standardized curve using the 256-bit prime @math
{
p = 2
^{
256
}
-
2
^{
224
}
+ 2
^{
192
}
+ 2
^{
96
}
- 1
}
. The contents of these structs is not
visible to nettle users. The ``bitsize of the curve'' is used as a
shorthand for the bitsize of the curve's prime @math
{
p
}
, e.g., 256 bits
for @code
{
nettle
_
secp
_
256r1
}
.
declared in @file
{
<nettle/ecc-curve.h>
}
, e.g.,
call
@code
{
nettle
_
get
_
secp
_
256r1
}
for a standardized curve using the 256-bit
prime @math
{
p = 2
^{
256
}
- 2
^{
224
}
+ 2
^{
192
}
+ 2
^{
96
}
- 1
}
. The contents
of these structs is not visible to nettle users. The ``bitsize of the
curve'' is used as a shorthand for the bitsize of the curve's prime
@math
{
p
}
, e.g., 256 bits for the SECP 256R1 curve
.
@menu
* Side-channel silence::
...
...
@@ -4473,7 +4497,7 @@ signature for the message digest @var{digest} (of @var{length} octets).
Returns 1 if the signature is valid, otherwise 0.
@end deftypefun
Finally,
to generation of new an ECDSA key pairs
Finally,
generating a new ECDSA key pair:
@deftypefun void ecdsa
_
generate
_
keypair (struct ecc
_
point *@var
{
pub
}
, struct ecc
_
scalar *@var
{
key
}
, void *@var
{
random
_
ctx
}
, nettle
_
random
_
func *@var
{
random
}
);
@var
{
pub
}
and @var
{
key
}
is where the resulting key pair is stored. The
...
...
@@ -5254,20 +5278,6 @@ option to be able to build with BSD make.
Local Variables:
ispell-local-dictionary: "american"
ispell-skip-region-alist: (
(ispell-words-keyword forward-line)
("
^
@example" . "
^
@end.*example")
("
^
@ignore" . "
^
@end.*ignore")
("
^
@
\\
(end
\\
|syncodeindex
\\
|vskip
\\
|
\\
(un
\\
)?macro
\\
|node
\\
|deftp
\\
) .*
$
"
)
(
"
^
@
\\
(
printindex
\\
|set
\\
)
.
*
$
")
("
^
@def.*
$
"
)
;; Allows one level of nested braces in the argument
(
"@
\\
(
uref
\\
|value
\\
|badspell
\\
|code
\\
|file
\\
|var
\\
|url
\\
)
{
[
^{}
]*
\\
(
{
[
^{}
]*
}
[
^{}
]*
\\
)*
}
"
)
(
"@
[
a
-
z
]+[
{
]
"
)
(
"@
[
a
-
z
]+
$
")
("
\input
texinfo.*
$
"
)
(
"ispell
-
ignore" . "ispell
-
end
-
ignore"
)
(
"
^
Local Variables:
$
" . "
^
End:
$
"
))
End:
@c LocalWords: cryptographics crypto LSH GNUPG API GPL LGPL aes rijndael ller
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment