ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: Sergey Vlasov <vsu@mivlgu.murom.ru>
To: mandrake-russian@altlinux.ru
Subject: Re: [mdk-re] Защитить дерево документов от чтения посторонним
Date: Wed Mar 13 18:31:42 2002
Message-ID: <20020313154048.GC9607@vcserver.mivlgu.ru> (raw)
In-Reply-To: <20020313181201.46c7e3e4.michael@michael.rsuh.ru>

On Wed, Mar 13, 2002 at 18:12:01 +0300, Michael Bykov wrote:
> > > Я пока придумал apache сделать владельцем, а права на фалы
> > > дать 460. Тогда apache не сможет писать в дерево документов,
> > > члены групп смогут работать, как привыкли, но не смогут
> > > видеть чужое дерево. Правильно? Как-то непривычно...
> > 
> > apache сможет сделать chmod.
> > 
> > -- 
> > Stay tuned,
> >   MhZ                                     JID:
> 
> А как он может сделать chmod, гад (права на запись-то у него не
> будет)?

Владелец файла (и только владелец) может сделать chmod, вне зависимости от
установленных прав доступа.

> Господа, неужели это не распространённая задачка? Подскажите,
> пока чтение меня не просветляет - опасно ли сделать apache
> владельцем своих файлов? (Чтобы убрать право на чтение
> "остальным"?)

Видимо, опасно.

Можно извратиться так:

1. Все, что надо скрыть, отдается не напрямую, а через CGI-скрипт, который
запускается через suexec.  Тогда для apache можно сделать доступным только
этот скрипт - а уже он, получив с помощью suexec права нужного
пользователя, будет доставать его файлы.

2. Файл самого скрипта содержит только include другого файла, который
никому, кроме этого пользователя, не доступен (чтобы не показывать даже
внутренность скрипта).

К сожалению, это увеличит нагрузку (никакие mod_perl, mod_php и т.п. тут
не годятся, т.к. все они выполняются только с правами apache).



  reply	other threads:[~2002-03-13 18:31 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-03-12 18:11 [mdk-re] (no subject) Michael Bykov
2002-03-12 19:52 ` [mdk-re] " Michael Shigorin
2002-03-12 20:07   ` Sergey Vlasov
2002-03-12 20:20   ` Michael Bykov
2002-03-12 20:26     ` Korshunov Ilya
2002-03-12 20:38       ` Michael Bykov
2002-03-12 20:45       ` Michael Bykov
2002-03-12 21:53         ` Michael Bykov
2002-03-13  1:11           ` Mikhail Zabaluev
2002-03-13 18:02             ` [mdk-re] Защитить дерево документов от чтения посторонним Michael Bykov
2002-03-13 18:31               ` Sergey Vlasov [this message]
2002-03-13 21:02                 ` Michael Bykov
2002-03-12 22:07 ` [mdk-re] Re: (no subject) Konstantin Lepikhov

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=20020313154048.GC9607@vcserver.mivlgu.ru \
    --to=vsu@mivlgu.murom.ru \
    --cc=mandrake-russian@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 Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/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 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git