Skip to content

Commit

Permalink
Merge cc16e4f into 369575c
Browse files Browse the repository at this point in the history
  • Loading branch information
paragonie-scott committed Jan 26, 2017
2 parents 369575c + cc16e4f commit edab71a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/rbnacl/group_elements/curve25519.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ def mult(integer)
Util.check_length(integer, SCALARBYTES, "integer")

result = Util.zeros(SCALARBYTES)
self.class.scalarmult_curve25519(result, integer, @point)
if self.class.scalarmult_curve25519(result, integer, @point) != 0
raise CryptoError "Invalid curve25519 result"
end

self.class.new(result)
end
Expand Down

0 comments on commit edab71a

Please sign in to comment.