type crypto/internal/fips140/bigmod.Modulus
40 uses
crypto/internal/fips140/bigmod (current package)
nat.go#L149: func (x *Nat) Bytes(m *Modulus) []byte {
nat.go#L174: func (x *Nat) SetBytes(b []byte, m *Modulus) (*Nat, error) {
nat.go#L190: func (x *Nat) SetOverflowingBytes(b []byte, m *Modulus) (*Nat, error) {
nat.go#L298: func (x *Nat) IsMinusOne(m *Modulus) choice {
nat.go#L467: type Modulus struct {
nat.go#L481: func rr(m *Modulus) *Nat {
nat.go#L551: func NewModulus(b []byte) (*Modulus, error) {
nat.go#L560: func NewModulusProduct(a, b []byte) (*Modulus, error) {
nat.go#L570: func newModulus(n *Nat) (*Modulus, error) {
nat.go#L571: m := &Modulus{nat: n}
nat.go#L584: func (m *Modulus) Size() int {
nat.go#L589: func (m *Modulus) BitLen() int {
nat.go#L594: func (m *Modulus) Nat() *Nat {
nat.go#L607: func (x *Nat) shiftIn(y uint, m *Modulus) *Nat {
nat.go#L648: func (out *Nat) Mod(x *Nat, m *Modulus) *Nat {
nat.go#L677: func (x *Nat) ExpandFor(m *Modulus) *Nat {
nat.go#L684: func (out *Nat) resetFor(m *Modulus) *Nat {
nat.go#L699: func (x *Nat) maybeSubtractModulus(always choice, m *Modulus) {
nat.go#L714: func (x *Nat) Sub(y *Nat, m *Modulus) *Nat {
nat.go#L726: func (x *Nat) SubOne(m *Modulus) *Nat {
nat.go#L740: func (x *Nat) Add(y *Nat, m *Modulus) *Nat {
nat.go#L753: func (x *Nat) montgomeryRepresentation(m *Modulus) *Nat {
nat.go#L763: func (x *Nat) montgomeryReduction(m *Modulus) *Nat {
nat.go#L779: func (x *Nat) montgomeryMul(a *Nat, b *Nat, m *Modulus) *Nat {
nat.go#L924: func (x *Nat) Mul(y *Nat, m *Modulus) *Nat {
nat.go#L987: func (out *Nat) Exp(x *Nat, e []byte, m *Modulus) *Nat {
nat.go#L1042: func (out *Nat) ExpShortVarTime(x *Nat, e uint, m *Modulus) *Nat {
nat.go#L1068: func (x *Nat) InverseVarTime(a *Nat, m *Modulus) (*Nat, bool) {
nat.go#L1158: A.Add(C, &Modulus{nat: m})
nat.go#L1159: B.Add(D, &Modulus{nat: a})
nat.go#L1162: C.Add(A, &Modulus{nat: m})
nat.go#L1163: D.Add(B, &Modulus{nat: a})
crypto/internal/fips140/ecdsa
ecdsa.go#L58: N *bigmod.Modulus
crypto/internal/fips140/rsa
keygen.go#L137: func totient(p, q *bigmod.Modulus) (*bigmod.Modulus, error) {
keygen.go#L341: w *bigmod.Modulus
rsa.go#L15: N *bigmod.Modulus
rsa.go#L33: p, q *bigmod.Modulus // p × q = n
rsa.go#L72: func newPrivateKey(n *bigmod.Modulus, e int, d *bigmod.Nat, p, q *bigmod.Modulus) (*PrivateKey, error) {