For writing safe code in C, you should also check Frama-C and CERT Secure Coding Standards.
http://frama-c.com/
https://www.securecoding.cert.org/confluence/display/seccode...
Even better, get the algorithms written in a theorem prover which is guaranteed to generate reliable safe C code.
This is approach taken by Microsoft with P Language(Windows USB device driver stack) and F* (new TLS implementation).
For writing safe code in C, you should also check Frama-C and CERT Secure Coding Standards.
http://frama-c.com/
https://www.securecoding.cert.org/confluence/display/seccode...
Even better, get the algorithms written in a theorem prover which is guaranteed to generate reliable safe C code.
This is approach taken by Microsoft with P Language(Windows USB device driver stack) and F* (new TLS implementation).