Matthias Görgens

Results 57 comments of Matthias Görgens

@mcarrickscott Rust has undefined behaviour. Just much less than C. Just to be clear: I am not suggesting to compile the release version with the sanitizer. I am suggesting to...

Here's the [shift-example](https://godbolt.org/#z:OYLghAFBqd5TKALEB7ArgFwA5YDQCWIEAxqgLbYEA2ApgE4ByAhubSAOQAeAHAGwBaPgBYA1MBIlRATgB0wjnloATAplT0CykAEY8AM1QA7TAGUSzOruEHjmAKoBnWgAUunAAyKAVrrwB3emZsTh0OAEo8ak4AVkUjT0VUTgB5LFxMUVR9UV5BEXFJGXlRCABhCio6elEAUgAmAGYdcMVMRPDIpFpmZQZiSIBrEBiPKM4FPHIRsYSOLzxkjkVHEDH2%2BYi8OFgUDBx8IlJKmgYWNk48oTEJKTlJlTUNLT9DE3NLdh0bN4dnN0SeF89QCQRCHDCkWiHDieDmCyWaQOmWyuX410KdxK5RO1TqTXqrTwGy8nTw3V6/QgUImimmozhgKWKzWxI6Qxm4w4jXiTM4bQ620QEBQZD6AFFVOp6IRiPpTkZWOwIYpfh8rN9bCYnK53JsgX5qMwjKAAPrmkh4Zx0EiYAjGYi0IzKCrUdDkBJ6J3KAAyBCMtEY7oARv1pHhsKhHGp7UZXe7PRGozHjH6A0HyKH6CBw9baLbY6ZMMx6Jh4x6/HmC8YiyXMGnAyGw1bi6Xy4nHK36/7G5mw5FHBh6CRlQ1Gv6SG6%2BrVGmVO6pULIkDPxbUPABBMcTqe0GdzzCqExLldr9f%2BzLkZj%2B6l1ADsACFT6JROeRKbMsGZ4%2BN8/g3VGgAIqIjRfk%2BojYJoJj6BADT1A0MTKP%2Bq6NOKogCDo/5AfB1DKLUMRlEYsF4KIwbEX%2BJ4oWhLSgT%2Boj0LQmDoPQRiiB4NGbreAGnls0KwvCSScGUoiDkxI74s0AqbJEIogGQlCnDKRxyVU/QkMA0g2H0ABuBAjgAagQtD%2BCk2BOqEqo0JgDCrBAwaAsG/olgAnuZeByWwJgpEY1AufqfSXiaVh%2BQQ9EFlptCrPqtBcPmWDKgs560NCCzUAQwZBPQTkVH0gKYJo0wqpE%2BhGsAjgGUZJlmSqWpmBYGo/HYOoAvqvh6EaJogOapqWqlwarJAkSoNgdrGJFKxJfmI0JBA3rtn43oNhmWZ%2BJG0ZTXNeirSmRiLU22Z6FWU21m2qBuhWB0TdWRjHd26Z7ZWXYbS2da7X2%2B0DkOI66DSMK8vqSxovkNxFPcpSSk8NRji0kmktsoq4gwsrHPJ1Syepmm0Dp%2BmGcZplzGEBiWdZxB2fqDmKplrnuU6mBeT5gL%2BcawBBQsqihXa4WRQs0WxVZgKJclii9RlWWoDl%2Bp5QQBWQgYJVlTjlX46qdjql8DXav8eoLMCURM51FpRGl/XUosw2xpFAgpDyVqXVNjrOk9C09kt/Sbcm62nQmK3u7Gr3LRdNpHY9nvnTbgeFl2fuu89J1nR2kfO/dLRWp9Xw/XxfIcIDGK3MUYgQOD0ridDbJSRyDLQpM0w6B4syZyyegkhEP31H9CL8qXpKROF9DRg6whAA%3D%3D) I mentioned. ```c #include #include int main() { int64_t b; b = 3; printf("%d >> -1 = %ld\n", b, b >> -1); return 0; } ``` Depending...

Yes, using the sanitizers in the tests can only verify the presence of problems, not their absence. The same applies for testing in general. Yes, avoiding negative shifts is a...

See also [Integer Undefined Behaviors in Open Source Crypto Libraries](https://blog.regehr.org/archives/1054)

Yes, Rust is great, I like it, too. But let's leave that tangent aside for now? To be clear, I am suggesting two things. First, in addition to the address...

Thanks for the discussion. If you treat undefined behaviour in a cryptographic library as not-a-bug, there's nothing further I can do here. I hope you'll never change the compiler version...

Alas, that doesn't work. You can't work around undefined behaviour like that. There's not guarantee that the compiler treats undefined constructs deterministically. Eg the same construct can give you different...