Skip to contentSkip to conversation

forbid to strace a program

DISCUSSION Andreas Hartmann 3 participants 3 messages Sep 3, 2005 – Sep 4, 2005 2 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#2 lore raw
Quoted 7 lines · Alex Riesen
Quoted 5 lines · Andreas Hartmann

Hello!

Is it possible to prevent a program to be straced on x86? What do I have to do, eg., to prevent a perl-program to be straced?

Quoted 5 lines

So that none can see what are you doing? Or because your program is breaking because of this? Probably nothing, but someone would like to know what it is you are doing and exactly how it breaks (and, if you don't mind -
why it breaks).

That's not really the problem. I want to hide a clear text password in that program (something like ssh-agent or gpg-agent; the last can be straced, too :-() which I need for a database when the program runs.

Is there another way to do this? If the password is crypted, I need a passphrase or something other to decrypt it again. Not really a solution of the problem.

Therefore, it would be best, to hide it by preventing stracing of the application to all users and root.

Ok, root could search for the password directly in the memory, but this would be not as easy as a strace.

Kind regards,
Andreas Hartmann

#3 lore raw
Quoted 9 lines

Is there another way to do this? If the password is crypted, I need a passphrase or something other to decrypt it again. Not really a solution of the problem.

Therefore, it would be best, to hide it by preventing stracing of the application to all users and root.

Ok, root could search for the password directly in the memory, but this would be not as easy as a strace.

Obfuscation isn't really valid security. Making something 'harder' to break isn't a solution unless you're making it hard enough that current technology can't break it (eg... you always have the brute force option, but good crypto intends to make such an option impossible without expending zillions of clock cycles).

Can I ask why you want to hide the database password from root?

Regards,
Chase Venters

#4 lore raw
In reply to Andreas Hartmann

Andreas Hartmann <[email protected]> wrote:

Quoted 4 lines · 1> Alex Riesen wrote:
Quoted 4 lines · Andreas Hartmann
Quoted 3 lines

Hello!
Is it possible to prevent a program to be straced on x86? What do I have to do, eg., to prevent a perl-program to be straced?

Look at the contortions shc does for this.

Quoted 9 lines
Quoted 5 lines

So that none can see what are you doing? Or because your program is breaking because of this? Probably nothing, but someone would like to know what it is you are doing and exactly how it breaks (and, if you don't mind -
why it breaks).

That's not really the problem. I want to hide a clear text password in that program (something like ssh-agent or gpg-agent; the last can be straced, too :-() which I need for a database when the program runs.

Anyone who can read the executable can find that out. In the worst case, by running it in a doctored environment that catches the password.

Place it in a file that noone else can read, that way it is also easier to change.

Signature · 4 lines
Dr. Horst H. von Brand                   User #22616 counter.li.org
Departamento de Informatica                     Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria              +56 32 654239
Casilla 110-V, Valparaiso, Chile                Fax:  +56 32 797513