You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var asn = require('asn1.js');
var Human = asn.define('Human', function() {
this.seq().obj(
this.key('firstName').int(),
);
});
var output = Human.encode({
firstName: 2500000000,
}, 'der');
var human = Human.decode(output, 'der');
console.log(human.firstName.toNumber());
It seems like an integer overflow. Shouldn't it allow more than 32 bits?
The text was updated successfully, but these errors were encountered:
The following snippet yields
63744
:It seems like an integer overflow. Shouldn't it allow more than 32 bits?
The text was updated successfully, but these errors were encountered: