3 ms·
If you feel the need to justify nmap being writting in C, which you shouldn't, just remember: The people who wrote nmap know C, and managed to write fucking nma
by burgerbrain 16y ago
If you feel the need to justify nmap being writting in C, which you shouldn't, just remember: The people who wrote nmap know C, and managed to write fucking nmap in it.
If you want a better one written in something else, then get cracking...
- tptacek 16y agoI don't even know what this is supposed to mean. Are you an avid C programmer? Or do you just really like nmap? I am asking seriously.
- GeneralMaximus 16y agoHe's just saying they used what they knew best. For example, there's no reason Git has to be written in C[1]. Mercurial, which is Python, is doing just fine. C is what Linus and the kernel hackers knew best. [1] Yeah, I know it was mostly hacked together using Bash and Perl, but that was a long time ago. Now it's mostly C. I'm suspecting they rewrote the performance-critical stuff in C, and left everything else alone. Not sure, though; I don't follow Git development.
- tptacek 16y agoI'm not criticizing Fyodor for writing nmap in C!
- burgerbrain 16y agoNot sure why I'm bothering to respond since you're being rather trolly.. but neither. I rarely program in C, and I rarely have a use for nmap. Rather I just intensely dislike when people pick language choice to focus on. You pick your language based on what your team knows, and if you can ship with it. Picking it for any other reason just makes you come off in a PHB type of way. If you have real criticisms and suggestions to make, then do so and make the world a better place in the process.
- tptacek 16y agoI'm not the one downvoting you; I just upvoted you. But you should re-read my comments. I don't have a problem with C.
- burgerbrain 16y agoThe issue is that "very little reason why the best scanner need be written in C" is a rather meaningless statement that verges on plain old flamebate.
- trevelyan 16y agoI think he's wrong here too. I can remember using nmap back in the really late 90s. Which wipes out a lot of languages that aren't C. C was and is a good choice. I'd be a lot more surprised if it was written in Java or Perl.
- tptacek 16y agoC is a bad choice for a new port scanner started in 2011. I've already written comments here justifying that statement. If you really think I'm wrong, it might be fun to hash out why. (I've got a fairly decent background in nmap's problem domain, for what it's worth.)
- trevelyan 16y agoI don't have a problem with C, although if I had to do it I would use C++ for object-oriented support and more or less guaranteed portability. Possibly also to compile in a lua interpreter. That said, I'm not a domain expert and was responding to the question of whether nmap should have been coded in C rather than what the best language would be for something started NOW. I don't know what the best alternatives would be and while I doubt I can contribute much to the discussion, I've read your other posts on security with interest and would be interested to hear which language you'd pick and why.