From: "Dmitry V. Levin" <ldv@altlinux.org>
To: ALT Devel discussion list <devel@altlinux.org>
Subject: Re: [devel] Re: suid/sgid programs and temporary files
Date: Wed, 17 Aug 2005 02:55:07 +0400
Message-ID: <20050816225507.GB8633@basalt.office.altlinux.org> (raw)
In-Reply-To: <20050816224428.GX19097@solemn.turbinal.org>
[-- Attachment #1: Type: text/plain, Size: 580 bytes --]
On Wed, Aug 17, 2005 at 02:44:28AM +0400, Alexey Tourbin wrote:
> On Wed, Aug 17, 2005 at 02:06:33AM +0400, Dmitry V. Levin wrote:
> > Выход - использовать mkstemp(3), который возвращает открытый дескриптор;
> > в этом случае файл может находится где угодно, и проблема может возникнуть
> > только с его удалением.
>
> Есть ещё tmpfile(3) из stdio. Надеюсь, он использует mkstemp(3). :)
Да, tmpfile(3) удаляет созданный файл сразу, и возвращает дескриптор на
файл, имени которому уже нет. Если кто-то не переименовал его между
open(2) и unlink(2). :)
--
ldv
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2005-08-16 22:55 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-16 19:31 [devel] " Alexey Tourbin
2005-08-16 19:56 ` Dmitry V. Levin
2005-08-16 21:42 ` [devel] " Alexey Tourbin
2005-08-16 22:06 ` Dmitry V. Levin
2005-08-16 22:34 ` Alexey Tourbin
2005-08-16 22:50 ` Dmitry V. Levin
2005-08-16 23:33 ` Alexey Tourbin
2005-08-16 23:38 ` Dmitry V. Levin
2005-08-16 23:52 ` Alexey Tourbin
2005-08-17 7:14 ` [devel] [wiki] " Michael Shigorin
2005-08-16 22:44 ` [devel] " Alexey Tourbin
2005-08-16 22:55 ` Dmitry V. Levin [this message]
2005-08-16 23:20 ` Alexey Tourbin
2005-08-16 23:30 ` Alexey Tourbin
2005-08-17 0:37 ` Alexey Tourbin
2005-08-17 0:46 ` Alexey Tourbin
2005-08-17 3:02 ` Andrey Rahmatullin
2005-08-17 6:37 ` Alexey Tourbin
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=20050816225507.GB8633@basalt.office.altlinux.org \
--to=ldv@altlinux.org \
--cc=devel@altlinux.org \
--cc=devel@altlinux.ru \
/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
ALT Linux Team development discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
public-inbox-index devel
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.devel
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git