Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Almost every security critical application I know of is written in C. I don't believe that there are any other language that has higher real status in producing secure applications.</p> <p>C is being said to be a poor language for security by people who don't understand. </p> <p>If you want C programmers to use your library, use C. Doing anything else is tying one hand behind your back whilst trying to walk on a balance beam (the gymnastics equipment). Sure, there are dozens of other languages that are CAPABLE of interfacing to C, but it typically involves using a C layer and then stuffing the C data types into a language specific data type (Java Objects, Python Objects, etc, etc), and when the call is finished, you use the same conversion back to a C data type. Just makes it harder to work with, and potentially slower if you don't get all the design decisions right. And people won't understand the source code, so won't like to use it (see more about this below). </p> <p>If you want security, then write very good code, wearing your "security aspects" hat firmly on at all times, find a security mailing list or website and post it there for review, take the review comments on board, understand the comments, and fix any comments that are meaningful to fix. Distribute the source code to the users, so people can see what your code does. Those that understand security will know what to look for and understand that you have done a good job (or a bad job, whichever is applicable) - and those who don't will hopefully trust the right pople. If it's good, people will use it. If it's "hidden", and not easy to access, you won't get many customers, no matter what language you use. </p> <p>Don't worry, you won't reveal anything more from releasing source. If there is a flaw in the code, and it is popular (or important) enough, someone will find the flaw, even if you publish only binaries. For those skilled in reverse engineering, not having source code is only a small obstacle. </p> <p>Security doesn't stem from using a specific language or a specific tool, it stems from good design and good basic understanding of the problems with security. </p> <p>And remember security by obscurity (whether that means "hidden source code" or "unusual language" or something else obscure) is false security. </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. COLots of security-centric open source projects have been shown to have the kinds of vulnerabilities that arise from using a non-pointer-safe language like C. Why should I believe that I'm a better programmer than all of them? If I can get the computer to do the work of ensuring that I haven't made those particular mistakes, it is more likely to do a thorough job.
      singulars
    2. COSince you are aware of the problems with using pointers, it should be relatively easy to know what areas to concentrate on. And languages then don't use pointers are typically written in C, which means that you end up with the same problem, but it's now hidden from your view [unless of course there is a "guaranteed safe language" - but so far I've not encountered a language that is guaranteed to be safe]. And of course, the point of codereview is that you get other people, who are experienced in finding flaws in code to look over the code - they will look for vulnerable use of pointers.
      singulars
    3. COC is also said to be a poor language for security by people who *do* understand. Consider for example the work of Mark Miller on the language E, the work of Jonathan Rees on W7, and recent work by Anil Madhavapeddy et al on Melange. The 2007 paper "Melange: Towards a "functional" Internet" ([PDF](http://anil.recoil.org/papers/2007-eurosys-melange.pdf)) uses OCaml for a combination of efficiency and security. See their Table 1, which lists OpenSSH CERT vulnerabilities attributable to language weaknesses.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload