latchset / kryoptic

a pkcs#11 software token written in Rust
GNU General Public License v3.0
10 stars 4 forks source link

Consider reviewing all uses of "as" conversions #77

Closed simo5 closed 1 month ago

simo5 commented 2 months ago

The "as" conversion truncates values when the receiving type is smaller leading to difficult to reason edge cases. We should review all uses of "as" to asses where try_from() is more appropriate.