Skip to content

Commit

Permalink
tink-android-HEAD-SNAPSHOT Javadoc auto-pushed to gh-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
Tink Team committed Sep 12, 2024
1 parent 7b311df commit 8b14b33
Show file tree
Hide file tree
Showing 3 changed files with 90 additions and 123 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
catch(err) {
}
//-->
var methods = {"i0":9,"i1":9,"i2":9,"i3":9,"i4":9,"i5":9,"i6":9,"i7":9,"i8":9,"i9":9,"i10":9,"i11":9,"i12":9,"i13":9,"i14":9,"i15":9,"i16":9,"i17":9,"i18":9,"i19":9,"i20":9,"i21":9,"i22":9,"i23":9,"i24":9,"i25":9,"i26":9,"i27":9,"i28":9,"i29":9,"i30":9};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],8:["t4","Concrete Methods"]};
var methods = {"i0":9,"i1":9,"i2":9,"i3":9,"i4":9,"i5":9,"i6":9,"i7":9,"i8":9,"i9":9,"i10":9,"i11":9,"i12":9,"i13":9,"i14":9,"i15":9,"i16":9,"i17":9,"i18":9,"i19":9,"i20":9,"i21":41,"i22":9,"i23":9,"i24":9,"i25":9,"i26":9,"i27":9,"i28":9,"i29":9};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],8:["t4","Concrete Methods"],32:["t6","Deprecated Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
Expand Down Expand Up @@ -161,7 +161,7 @@ <h3>Nested Class Summary</h3>
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t6" class="tableTab"><span><a href="javascript:show(32);">Deprecated Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
Expand Down Expand Up @@ -253,8 +253,8 @@ <h3>Method Summary</h3>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces">ECPublicKey</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#getEcPublicKey-byte:A-">getEcPublicKey</a></span>(byte[]&nbsp;x509PublicKey)</code>
<div class="block">Returns an <a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces"><code>ECPublicKey</code></a> from <code>x509PublicKey</code> which is an encoding of a public
key, encoded according to the ASN.1 type SubjectPublicKeyInfo.</div>
<div class="block">Returns an <a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces"><code>ECPublicKey</code></a> from <code>x509PublicKey</code> which is an encoding of a public key,
encoded according to the ASN.1 type SubjectPublicKeyInfo.</div>
</td>
</tr>
<tr id="i14" class="altColor">
Expand Down Expand Up @@ -306,7 +306,9 @@ <h3>Method Summary</h3>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#getY-java.math.BigInteger-boolean-java.security.spec.EllipticCurve-">getY</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;x,
boolean&nbsp;lsb,
<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/EllipticCurve.html?is-external=true" title="class or interface in java.security.spec">EllipticCurve</a>&nbsp;curve)</code>
<div class="block">Computes the y coordinate of a point on an elliptic curve.</div>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;
<div class="block"><span class="deprecationComment">This shouldn't be used directly, use <code>pointDecode</code> to decompress points.</span></div>
</div>
</td>
</tr>
<tr id="i22" class="altColor">
Expand All @@ -327,45 +329,38 @@ <h3>Method Summary</h3>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#isValidDerEncoding-byte:A-">isValidDerEncoding</a></span>(byte[]&nbsp;sig)</code>&nbsp;</td>
</tr>
<tr id="i25" class="rowColor">
<td class="colFirst"><code>protected static <a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#modSqrt-java.math.BigInteger-java.math.BigInteger-">modSqrt</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;x,
<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;p)</code>
<div class="block">Computes a square root modulo an odd prime.</div>
</td>
</tr>
<tr id="i26" class="altColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/ECPoint.html?is-external=true" title="class or interface in java.security.spec">ECPoint</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#pointDecode-java.security.spec.EllipticCurve-com.google.crypto.tink.subtle.EllipticCurves.PointFormatType-byte:A-">pointDecode</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/EllipticCurve.html?is-external=true" title="class or interface in java.security.spec">EllipticCurve</a>&nbsp;curve,
<a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.PointFormatType.html" title="enum in com.google.crypto.tink.subtle">EllipticCurves.PointFormatType</a>&nbsp;format,
byte[]&nbsp;encoded)</code>
<div class="block">Decodes an encoded point on an elliptic curve.</div>
</td>
</tr>
<tr id="i27" class="rowColor">
<tr id="i26" class="altColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/ECPoint.html?is-external=true" title="class or interface in java.security.spec">ECPoint</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#pointDecode-com.google.crypto.tink.subtle.EllipticCurves.CurveType-com.google.crypto.tink.subtle.EllipticCurves.PointFormatType-byte:A-">pointDecode</a></span>(<a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.CurveType.html" title="enum in com.google.crypto.tink.subtle">EllipticCurves.CurveType</a>&nbsp;curveType,
<a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.PointFormatType.html" title="enum in com.google.crypto.tink.subtle">EllipticCurves.PointFormatType</a>&nbsp;format,
byte[]&nbsp;encoded)</code>
<div class="block">Decodes an encoded point on an elliptic curve.</div>
</td>
</tr>
<tr id="i28" class="altColor">
<tr id="i27" class="rowColor">
<td class="colFirst"><code>static byte[]</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#pointEncode-java.security.spec.EllipticCurve-com.google.crypto.tink.subtle.EllipticCurves.PointFormatType-java.security.spec.ECPoint-">pointEncode</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/EllipticCurve.html?is-external=true" title="class or interface in java.security.spec">EllipticCurve</a>&nbsp;curve,
<a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.PointFormatType.html" title="enum in com.google.crypto.tink.subtle">EllipticCurves.PointFormatType</a>&nbsp;format,
<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/ECPoint.html?is-external=true" title="class or interface in java.security.spec">ECPoint</a>&nbsp;point)</code>
<div class="block">Encodes a point on an elliptic curve.</div>
</td>
</tr>
<tr id="i29" class="rowColor">
<tr id="i28" class="altColor">
<td class="colFirst"><code>static byte[]</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#pointEncode-com.google.crypto.tink.subtle.EllipticCurves.CurveType-com.google.crypto.tink.subtle.EllipticCurves.PointFormatType-java.security.spec.ECPoint-">pointEncode</a></span>(<a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.CurveType.html" title="enum in com.google.crypto.tink.subtle">EllipticCurves.CurveType</a>&nbsp;curveType,
<a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.PointFormatType.html" title="enum in com.google.crypto.tink.subtle">EllipticCurves.PointFormatType</a>&nbsp;format,
<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/ECPoint.html?is-external=true" title="class or interface in java.security.spec">ECPoint</a>&nbsp;point)</code>
<div class="block">Encodes a point on an elliptic curve.</div>
</td>
</tr>
<tr id="i30" class="altColor">
<tr id="i29" class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/google/crypto/tink/subtle/EllipticCurves.html#validatePublicKey-java.security.interfaces.ECPublicKey-java.security.interfaces.ECPrivateKey-">validatePublicKey</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces">ECPublicKey</a>&nbsp;publicKey,
<a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPrivateKey.html?is-external=true" title="class or interface in java.security.interfaces">ECPrivateKey</a>&nbsp;privateKey)</code>
Expand Down Expand Up @@ -519,51 +514,22 @@ <h4>fieldSizeInBytes</h4>
</dl>
</li>
</ul>
<a name="modSqrt-java.math.BigInteger-java.math.BigInteger-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>modSqrt</h4>
<pre>protected static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;modSqrt(<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;x,
<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;p)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></pre>
<div class="block">Computes a square root modulo an odd prime. Timing and exceptions can leak information about
the inputs. Therefore this method must only be used to decompress public keys.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>x</code> - the square</dd>
<dd><code>p</code> - the prime modulus (the behaviour of the method is undefined if p is not prime).</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a value s such that s^2 mod p == x mod p</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></code> - if the square root could not be found.</dd>
</dl>
</li>
</ul>
<a name="getY-java.math.BigInteger-boolean-java.security.spec.EllipticCurve-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getY</h4>
<pre>public static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;getY(<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;x,
boolean&nbsp;lsb,
<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/EllipticCurve.html?is-external=true" title="class or interface in java.security.spec">EllipticCurve</a>&nbsp;curve)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></pre>
<div class="block">Computes the y coordinate of a point on an elliptic curve. This method can be used to
decompress elliptic curve points.</div>
<pre><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
public static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;getY(<a href="https://docs.oracle.com/javase/8/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</a>&nbsp;x,
boolean&nbsp;lsb,
<a href="https://docs.oracle.com/javase/8/docs/api/java/security/spec/EllipticCurve.html?is-external=true" title="class or interface in java.security.spec">EllipticCurve</a>&nbsp;curve)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></pre>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;<span class="deprecationComment">This shouldn't be used directly, use <code>pointDecode</code> to decompress points.</span></div>
<div class="block">Computes the y coordinate of a point on an elliptic curve.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>x</code> - the x-coordinate of the point</dd>
<dd><code>lsb</code> - the least significant bit of the y-coordinate of the point.</dd>
<dd><code>curve</code> - this must be an elliptic curve over a prime field using Weierstrass
representation.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the y coordinate.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></code> - if there is no point with coordinate x on the curve, or if
curve is not supported.</dd>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></code></dd>
</dl>
</li>
</ul>
Expand Down Expand Up @@ -695,7 +661,7 @@ <h4>pointDecode</h4>
the curve.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>curve</code> - the elliptic curve</dd>
<dd><code>curveType</code> - the elliptic curve</dd>
<dd><code>format</code> - the format used to enocde the point</dd>
<dd><code>encoded</code> - the encoded point</dd>
<dt><span class="returnLabel">Returns:</span></dt>
Expand Down Expand Up @@ -748,7 +714,7 @@ <h4>pointEncode</h4>
<div class="block">Encodes a point on an elliptic curve.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>curve</code> - the elliptic curve</dd>
<dd><code>curveType</code> - the elliptic curve</dd>
<dd><code>format</code> - the format for the encoding</dd>
<dd><code>point</code> - the point to encode</dd>
<dt><span class="returnLabel">Returns:</span></dt>
Expand Down Expand Up @@ -814,11 +780,10 @@ <h4>getCurveSpec</h4>
<h4>getEcPublicKey</h4>
<pre>public static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces">ECPublicKey</a>&nbsp;getEcPublicKey(byte[]&nbsp;x509PublicKey)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></pre>
<div class="block">Returns an <a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces"><code>ECPublicKey</code></a> from <code>x509PublicKey</code> which is an encoding of a public
key, encoded according to the ASN.1 type SubjectPublicKeyInfo.
<div class="block">Returns an <a href="https://docs.oracle.com/javase/8/docs/api/java/security/interfaces/ECPublicKey.html?is-external=true" title="class or interface in java.security.interfaces"><code>ECPublicKey</code></a> from <code>x509PublicKey</code> which is an encoding of a public key,
encoded according to the ASN.1 type SubjectPublicKeyInfo.

TODO(b/68672497): test that in Java one can always get this representation by using
{@link ECPublicKey#getEncoded), regardless of the provider.</div>
<p>TODO(b/68672497): test that in Java one can always get this representation by using <a href="https://docs.oracle.com/javase/8/docs/api/java/security/Key.html?is-external=true#getEncoded--" title="class or interface in java.security"><code>Key.getEncoded()</code></a>, regardless of the provider.</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></code></dd>
Expand Down Expand Up @@ -889,8 +854,7 @@ <h4>getEcPrivateKey</h4>
<div class="block">Returns an <code>ECPrivateKey</code> from <code>pkcs8PrivateKey</code> which is an encoding of a private
key, encoded according to the ASN.1 type SubjectPublicKeyInfo.

TODO(b/68672497): test that in Java one can always get this representation by using
{@link ECPrivateKey#getEncoded), regardless of the provider.</div>
<p>TODO(b/68672497): test that in Java one can always get this representation by using <a href="https://docs.oracle.com/javase/8/docs/api/java/security/Key.html?is-external=true#getEncoded--" title="class or interface in java.security"><code>Key.getEncoded()</code></a>, regardless of the provider.</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/security/GeneralSecurityException.html?is-external=true" title="class or interface in java.security">GeneralSecurityException</a></code></dd>
Expand Down
Loading

0 comments on commit 8b14b33

Please sign in to comment.