Paul G. Allen wrote:
Christopher Smith wrote:
Sure, but the rational way to do that is to provide a function or
even better a command that can be invoked to extract that information
(typically "-v" or "--version"), which, in turn, means some code
which actually touches the string and/or the string being an exported
data bit. Either way, super visible so the compiler can't remove it.
Which would be useless if the application can't run well enough to
execute the command. Been there, done that. Also, think embedded
systems where space is at a premium and adding extra functions is like
purchasing a mountain of platinum.
I'm trying to think of reasons why this would be the case.... It would
imply that you can't spawn a process (which would cause problems for
just about any technique) or the executable has been corrupted (in which
case you are screwed anyway). Finally, either way, the "strings" based
approach would *still work*, it's just that you'd have a more convenient
way to grab that information in the event that things are working well
enough to use it.
I'm clearly missing something here.
--Chris
--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-lpsg