Source file src/crypto/ecdsa/ecdsa_noasm.go

Documentation: crypto/ecdsa

     1  // Copyright 2019 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  // +build !s390x
     6  
     7  package ecdsa
     8  
     9  import (
    10  	"crypto/cipher"
    11  	"crypto/elliptic"
    12  	"math/big"
    13  )
    14  
    15  func sign(priv *PrivateKey, csprng *cipher.StreamReader, c elliptic.Curve, e *big.Int) (r, s *big.Int, err error) {
    16  	r, s, err = signGeneric(priv, csprng, c, e)
    17  	return
    18  }
    19  
    20  func verify(pub *PublicKey, c elliptic.Curve, e, r, s *big.Int) bool {
    21  	return verifyGeneric(pub, c, e, r, s)
    22  }
    23  

View as plain text