From: Oliver Welter <mail@oliwel.de>
To: Tavis Ormandy <taviso@sdf.lonestar.org>
Cc: gdb@sourceware.org
Subject: Re: How to protect a file from debugging
Date: Mon, 11 Jun 2007 09:25:00 -0000 [thread overview]
Message-ID: <466D14D5.4020007@oliwel.de> (raw)
In-Reply-To: <20070611091627.GB8386@sdf.lonestar.org>
[-- Attachment #1: Type: text/plain, Size: 1132 bytes --]
Hi Tavis
> The short answer is no, any tricks you attempt to use to prevent
> ptrace() can be defeated (some more easily than others), however if you
> explain what the "troubles" are there may be a better solution.
>
damn ;)
Ok here is what I am planing:
I have an application, lets say a simple text editor, that is used to
read/write sensitive information.
Now I start gdb, attach it to the process and call "gcore" which - for
my understanding - dumps the entire memory of the process to a file. So
the core dump reveals my secret data.
What I want to do is, to either prevent gdb from attaching and capturing
the memory or at least find a way to recognize when a program attaches
another. I am a noob regarding the internal system structure, so I dont
know exactly what gdb does to attach to a program, but I guess there is
a syscall or similar that is used to pass the memory location to gdb and
if I block/supervise that, I might find a way around....
Oliver
--
Protect your environment - close windows and adopt a penguin!
PGP-Key: 3B2C 8095 A7DF 8BB5 2CFF 8168 CAB7 B0DD 3985 1721
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2007-06-11 9:25 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-11 8:17 Oliver Welter
2007-06-11 9:16 ` Tavis Ormandy
2007-06-11 9:25 ` Oliver Welter [this message]
2007-06-11 9:32 ` Andreas Schwab
2007-06-11 9:38 ` Oliver Welter
2007-06-11 10:04 ` Tavis Ormandy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=466D14D5.4020007@oliwel.de \
--to=mail@oliwel.de \
--cc=gdb@sourceware.org \
--cc=taviso@sdf.lonestar.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox