math/big.Int.BitLen (method)
31 uses
math/big (current package)
float.go#L604: bits := uint32(x.BitLen())
int.go#L546: func (x *Int) BitLen() int {
crypto/dsa
dsa.go#L124: if p.BitLen() < L {
dsa.go#L165: xBytes := make([]byte, priv.Q.BitLen()/8)
dsa.go#L210: n := priv.Q.BitLen()
dsa.go#L292: n := pub.Q.BitLen()
crypto/ecdsa
ecdsa.go#L100: size := (k.Curve.Params().N.BitLen() + 7) / 8
ecdsa.go#L101: if k.D.BitLen() > size*8 {
ecdsa.go#L586: if x.BitLen() > bitSize || y.BitLen() > bitSize {
ecdsa_legacy.go#L37: orderBits := c.Params().N.BitLen()
ecdsa_legacy.go#L176: b := make([]byte, (N.BitLen()+7)/8)
ecdsa_legacy.go#L180: if excess := len(b)*8 - N.BitLen(); excess > 0 {
crypto/elliptic
elliptic.go#L77: bitSize := N.BitLen()
nistec.go#L149: if x.BitLen() > curve.params.BitSize || y.BitLen() > curve.params.BitSize {
nistec.go#L197: byteSize := (curve.params.N.BitLen() + 7) / 8
crypto/rand
util.go#L69: bitLen := n.BitLen()
crypto/rsa
pss.go#L211: emBits := priv.N.BitLen() - 1
pss.go#L315: saltLength = (priv.N.BitLen()-1+7)/8 - 2 - hash.Size()
pss.go#L362: emBits := pub.N.BitLen() - 1
rsa.go#L57: return (pub.N.BitLen() + 7) / 8
rsa.go#L396: todo -= primes[i].BitLen()
rsa.go#L416: if n.BitLen() != bits {
crypto/tls
handshake_client.go#L971: n := cert.cert.PublicKey.(*rsa.PublicKey).N.BitLen()
handshake_server.go#L868: n := certs[i].PublicKey.(*rsa.PublicKey).N.BitLen()
handshake_server_tls13.go#L711: rsaKey.N.BitLen()/8 < sigHash.Size()*2+2 { // key too small for RSA-PSS
crypto/x509
sec1.go#L61: privateKey := make([]byte, (key.Curve.Params().N.BitLen()+7)/8)
sec1.go#L118: privateKey := make([]byte, (curveOrder.BitLen()+7)/8)
github.com/gotd/td/internal/crypto
check_dh.go#L31: if p.BitLen() != RSAKeyBits {
fill_bytes.go#L9: bits := b.BitLen()
The pages are generated with Golds v0.6.7. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |