- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 93 for biglen (0.12 sec)
-
src/crypto/dsa/dsa.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Oct 13 17:09:47 UTC 2023 - 7.2K bytes - Viewed (0) -
src/crypto/rand/util.go
} n = new(big.Int) n.Sub(max, n.SetUint64(1)) // bitLen is the maximum bit length needed to encode a value < max. bitLen := n.BitLen() if bitLen == 0 { // the only valid result is 0 return } // k is the maximum byte length needed to encode a value < max. k := (bitLen + 7) / 8 // b is the number of bits in the most significant byte of max-1. b := uint(bitLen % 8) if b == 0 { b = 8 }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Oct 13 17:09:47 UTC 2023 - 2.4K bytes - Viewed (0) -
src/crypto/internal/boring/ecdsa.go
size := C._goboringcrypto_ECDSA_size(priv.key) sig := make([]byte, size) var sigLen C.uint if C._goboringcrypto_ECDSA_sign(0, base(hash), C.size_t(len(hash)), base(sig), &sigLen, priv.key) == 0 { return nil, fail("ECDSA_sign") } runtime.KeepAlive(priv) return sig[:sigLen], nil } func VerifyECDSA(pub *PublicKeyECDSA, hash []byte, sig []byte) bool {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Jul 20 17:51:31 UTC 2023 - 4.7K bytes - Viewed (0) -
src/os/user/cgo_lookup_cgo.go
#include <string.h> static struct passwd mygetpwuid_r(int uid, char *buf, size_t buflen, int *found, int *perr) { struct passwd pwd; struct passwd *result; memset (&pwd, 0, sizeof(pwd)); *perr = getpwuid_r(uid, &pwd, buf, buflen, &result); *found = result != NULL; return pwd; } static struct passwd mygetpwnam_r(const char *name, char *buf, size_t buflen, int *found, int *perr) { struct passwd pwd; struct passwd *result;
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Dec 16 17:45:51 UTC 2022 - 3.4K bytes - Viewed (0) -
src/crypto/ecdsa/ecdsa_legacy.go
// signatures will come out different from other architectures, which will // break TLS recorded tests. for { N := c.Params().N b := make([]byte, (N.BitLen()+7)/8) if _, err = io.ReadFull(rand, b); err != nil { return } if excess := len(b)*8 - N.BitLen(); excess > 0 { b[0] >>= excess } k = new(big.Int).SetBytes(b) if k.Sign() != 0 && k.Cmp(N) < 0 { return } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 00:11:18 UTC 2024 - 4.8K bytes - Viewed (0) -
src/crypto/internal/nistec/nistec_test.go
fatalIfErr(t, err) g1.Add(g1, p1) if !bytes.Equal(g1.Bytes(), newPoint().Bytes()) { t.Error("[N - k]G + [k]G != ∞") } } byteLen := len(c.Params().N.Bytes()) bitLen := c.Params().N.BitLen() t.Run("0", func(t *testing.T) { checkScalar(t, make([]byte, byteLen)) }) t.Run("1", func(t *testing.T) { checkScalar(t, big.NewInt(1).FillBytes(make([]byte, byteLen))) })
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 12 18:48:23 UTC 2023 - 8.4K bytes - Viewed (0) -
docs/en/docs/tutorial/dependencies/global-dependencies.md
## Dependencies for groups of *path operations*
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Tue Oct 17 05:59:11 UTC 2023 - 1.4K bytes - Viewed (0) -
src/crypto/x509/boring.go
return true } // The key must be RSA 2048, RSA 3072, RSA 4096, // or ECDSA P-256, P-384, P-521. switch k := c.PublicKey.(type) { default: return false case *rsa.PublicKey: if size := k.N.BitLen(); size != 2048 && size != 3072 && size != 4096 { return false } case *ecdsa.PublicKey: if k.Curve != elliptic.P256() && k.Curve != elliptic.P384() && k.Curve != elliptic.P521() { return false } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Jan 26 22:52:27 UTC 2024 - 993 bytes - Viewed (0) -
src/crypto/x509/sec1.go
if !key.Curve.IsOnCurve(key.X, key.Y) { return nil, errors.New("invalid elliptic key public key") } privateKey := make([]byte, (key.Curve.Params().N.BitLen()+7)/8) return asn1.Marshal(ecPrivateKey{ Version: 1, PrivateKey: key.D.FillBytes(privateKey), NamedCurveOID: oid, PublicKey: asn1.BitString{Bytes: elliptic.Marshal(key.Curve, key.X, key.Y)}, })
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Oct 13 17:09:47 UTC 2023 - 4.6K bytes - Viewed (0) -
src/go/importer/importer_test.go
imp := ForCompiler(fset, compiler, lookup) pkg, err := imp.Import("math/bigger") if err != nil { t.Fatal(err) } // Even though we open math/big.a, the import request was for math/bigger // and that should be recorded in pkg.Path(), at least for the gc toolchain. if pkg.Path() != "math/bigger" { t.Fatalf("Path() = %q, want %q", pkg.Path(), "math/bigger") } })
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jan 25 21:16:32 UTC 2023 - 2.8K bytes - Viewed (0)