aboutsummaryrefslogtreecommitdiffstats
path: root/lib/crypto/doc
diff options
context:
space:
mode:
authorAndreas Schultz <[email protected]>2012-09-12 20:57:01 +0200
committerIngela Anderton Andin <[email protected]>2013-03-28 11:29:37 +0100
commitd8144ef38f7e18230349100bbdee1da4c723fd94 (patch)
tree4d79acb8b6112d5b43bf2de9a2dd12bfbe71bca0 /lib/crypto/doc
parent9dea5a397111f1e049f10b9e1a2d6f70a9db6a95 (diff)
downloadotp-d8144ef38f7e18230349100bbdee1da4c723fd94.tar.gz
otp-d8144ef38f7e18230349100bbdee1da4c723fd94.tar.bz2
otp-d8144ef38f7e18230349100bbdee1da4c723fd94.zip
CRYPTO: add support for RFC-2945 SRP-3 and RFC-5054 SRP-6a authentication
Diffstat (limited to 'lib/crypto/doc')
-rwxr-xr-xlib/crypto/doc/src/crypto.xml88
1 files changed, 87 insertions, 1 deletions
diff --git a/lib/crypto/doc/src/crypto.xml b/lib/crypto/doc/src/crypto.xml
index 6b9b2ef207..d4224e773c 100755
--- a/lib/crypto/doc/src/crypto.xml
+++ b/lib/crypto/doc/src/crypto.xml
@@ -973,7 +973,17 @@ Mpint() = <![CDATA[<<ByteLen:32/integer-big, Bytes:ByteLen/binary>>]]>
using the <c>crypto</c> library.</p>
</desc>
</func>
-
+ <func>
+ <name>mod_exp_prime(N, P, M) -> Result</name>
+ <fsummary>Computes the function: N^P mod M</fsummary>
+ <type>
+ <v>N, P, M = binary()</v>
+ <v>Result = binary() | error</v>
+ </type>
+ <desc>
+ <p>Computes the function <c>N^P mod M</c>.</p>
+ </desc>
+ </func>
<func>
<name>rsa_sign(DataOrDigest, Key) -> Signature</name>
<name>rsa_sign(DigestType, DataOrDigest, Key) -> Signature</name>
@@ -1256,6 +1266,82 @@ Mpint() = <![CDATA[<<ByteLen:32/integer-big, Bytes:ByteLen/binary>>]]>
</desc>
</func>
+ <func>
+ <name>srp_value_B(Multiplier, Verifier, Generator, Exponent, Prime) -> ValueB</name>
+ <fsummary>Computes the SRP function: B = k*v + g^b % N</fsummary>
+ <type>
+ <v>Verifier (v), Generator (g), Exponent (b), Prime (N), ValueB (B) = binary()</v>
+ <v>Multiplier (k) = integer() | binary()</v>
+ </type>
+ <desc>
+ <p>Computes the SRP value B according to RFC-2945, Sect. 3 and RFC-5054, Sect. 2.5.3</p>
+ <p>B = k*v + g^b % N</p>
+ </desc>
+ </func>
+
+ <func>
+ <name>srp_client_secret(A, U, B, Multiplier, Generator, Exponent, Prime) -> Secret</name>
+ <fsummary>Computes the SRP client secret</fsummary>
+ <type>
+ <v>A (a), U (u), B, Multiplier (k), Generator (g), Exponent (x), Prime (N), Secret = binary()</v>
+ <v>Multiplier (k) = integer() | binary()</v>
+ </type>
+ <desc>
+ <p>Computes the SRP client secret according to RFC-2945, Sect. 3 and RFC-5054, Sect. 2.6</p>
+ <p>Secret = (B - (k * g^x)) ^ (a + (u * x)) % N</p>
+ </desc>
+ </func>
+
+ <func>
+ <name>srp_server_secret(Verifier, B, U, A, Prime) -> Secret</name>
+ <fsummary>Computes the SRP host secret</fsummary>
+ <type>
+ <v>Verifier (v), B (b), U (u), A, Prime (N), Secret = binary()</v>
+ </type>
+ <desc>
+ <p>Computes the SRP host secret according to RFC-2945, Sect. 3 and RFC-5054, Sect. 2.6</p>
+ <p>Secret = (A * v^u) ^ b % N</p>
+ </desc>
+ </func>
+
+ <func>
+ <name>srp3_value_u(B) -> Result</name>
+ <fsummary>Computes the SRP3-SHA value u</fsummary>
+ <type>
+ <v>B = binary()</v>
+ <v>Result = integer()</v>
+ </type>
+ <desc>
+ <p>Computes the SRP-3 value u according to RFC-2945, Sect. 3
+ </p>
+ </desc>
+ </func>
+
+ <func>
+ <name>srp6_value_u(A, B, Prime) -> Result</name>
+ <fsummary>Computes the SRP6a value u as u = SHA1(PAD(A) | PAD(B))</fsummary>
+ <type>
+ <v>A, B, Prime = binary()</v>
+ <v>Result = integer()</v>
+ </type>
+ <desc>
+ <p>Computes the SRP-6 value u according to RFC-5054, Sect. 2.6
+ </p>
+ </desc>
+ </func>
+
+ <func>
+ <name>srp6a_multiplier(Generator, Prime) -> Result</name>
+ <fsummary>Computes the SRP-SHA function: k = SHA1(N | PAD(g))</fsummary>
+ <type>
+ <v>Generator, Prime = binary()</v>
+ <v>Result = integer()</v>
+ </type>
+ <desc>
+ <p>Computes the SRP-6a function SHA1(N | PAD(g)) as the multiplier
+ </p>
+ </desc>
+ </func>
<func>
<name>exor(Data1, Data2) -> Result</name>