mirror of
https://github.com/schollz/croc.git
synced 2025-10-11 05:11:06 +02:00
add siec as default
This commit is contained in:
parent
f6abf9c4e8
commit
ae7ceca3b7
1 changed files with 5 additions and 4 deletions
|
@ -11,7 +11,10 @@ import (
|
|||
"os"
|
||||
"strconv"
|
||||
|
||||
"github.com/schollz/croc/src/pake"
|
||||
|
||||
"github.com/pkg/errors"
|
||||
"github.com/tscholl2/siec"
|
||||
)
|
||||
|
||||
// catFiles copies data from n files to a single one and removes source files
|
||||
|
@ -71,7 +74,7 @@ func splitFile(fileName string, numPieces int) (err error) {
|
|||
return nil
|
||||
}
|
||||
|
||||
func getCurve(s string) (curve elliptic.Curve) {
|
||||
func getCurve(s string) (curve pake.EllipticCurve) {
|
||||
switch s {
|
||||
case "p224":
|
||||
curve = elliptic.P224()
|
||||
|
@ -82,9 +85,7 @@ func getCurve(s string) (curve elliptic.Curve) {
|
|||
case "p521":
|
||||
curve = elliptic.P521()
|
||||
default:
|
||||
// TODO:
|
||||
// add SIEC
|
||||
curve = elliptic.P256()
|
||||
curve = siec.SIEC255()
|
||||
}
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue