Skip to content

Commit

Permalink
delete limit of encrypted msg
Browse files Browse the repository at this point in the history
  • Loading branch information
boohyunsik committed Jun 29, 2019
1 parent 99135aa commit 5bb7c1a
Show file tree
Hide file tree
Showing 4 changed files with 76 additions and 67 deletions.
133 changes: 71 additions & 62 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions public_key.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ func (p *PublicKey) Verify(sig *Signature, msg []byte) bool {

func (p *PublicKey) Encrypt(msg []byte) (*CipherText, error) {

if len(msg) > 32 {
return nil, nil
}
//if len(msg) > 32 {
// return nil, nil
//}

r, err := bls.RandFR(rand.Reader)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion tpke_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ func TestTPKE(t *testing.T) {
david := playGround.actors[3].id
eric := playGround.actors[4].id

msg := []byte("pizza pizza")
msg := []byte("pizza pizza pizza pizza pizza pizza pizza pizza pizza pizza pizza pizza pizza")
t.Logf("msg : %v", msg)
cipherText, err := pk.Encrypt(msg)

Expand Down
Loading

0 comments on commit 5bb7c1a

Please sign in to comment.