* [devel] лимиты и "сервисы" @ 2006-08-23 10:06 Sergey Pinaev 2006-08-23 11:00 ` Dmitry V. Levin 2006-08-23 14:13 ` Alexey I. Froloff 0 siblings, 2 replies; 12+ messages in thread From: Sergey Pinaev @ 2006-08-23 10:06 UTC (permalink / raw) To: devel hi. а не пора ли нам чего-нибудь придумать на тему установок лимитов (как минимум) для сервисов, самостоятельно делающих setuid? например очень бы хотелось этого для апача. -- mail="Sergey Pinaev <dfo@antex.ru>" url="http://`echo $mail | sed 's/.* <\(.*\)@\(.*\)>/\1.\2/'`" ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 10:06 [devel] лимиты и "сервисы" Sergey Pinaev @ 2006-08-23 11:00 ` Dmitry V. Levin 2006-08-23 12:04 ` Sergey Pinaev 2006-08-23 14:13 ` Alexey I. Froloff 1 sibling, 1 reply; 12+ messages in thread From: Dmitry V. Levin @ 2006-08-23 11:00 UTC (permalink / raw) To: ALT Devel discussion list [-- Attachment #1: Type: text/plain, Size: 308 bytes --] On Wed, Aug 23, 2006 at 02:06:05PM +0400, Sergey Pinaev wrote: > hi. > а не пора ли нам чего-нибудь придумать на тему установок > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > например очень бы хотелось этого для апача. PAM использовать нет никакой возможности? -- ldv [-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 11:00 ` Dmitry V. Levin @ 2006-08-23 12:04 ` Sergey Pinaev 2006-08-23 12:26 ` Dmitry V. Levin 0 siblings, 1 reply; 12+ messages in thread From: Sergey Pinaev @ 2006-08-23 12:04 UTC (permalink / raw) To: ALT Devel discussion list On Wed, 23 Aug 2006 15:00:21 +0400 "Dmitry V. Levin" <ldv@altlinux.org> wrote: > > а не пора ли нам чего-нибудь придумать на тему установок > > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > > например очень бы хотелось этого для апача. > > PAM использовать нет никакой возможности? а как? я, возможно, туплю, но я не понимаю каким боком его тут прикрутить. -- mail="Sergey Pinaev <dfo@antex.ru>" url="http://`echo $mail | sed 's/.* <\(.*\)@\(.*\)>/\1.\2/'`" ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 12:04 ` Sergey Pinaev @ 2006-08-23 12:26 ` Dmitry V. Levin 2006-08-23 13:10 ` Sergey Pinaev 0 siblings, 1 reply; 12+ messages in thread From: Dmitry V. Levin @ 2006-08-23 12:26 UTC (permalink / raw) To: ALT Devel discussion list [-- Attachment #1: Type: text/plain, Size: 549 bytes --] On Wed, Aug 23, 2006 at 04:04:44PM +0400, Sergey Pinaev wrote: > On Wed, 23 Aug 2006 15:00:21 +0400 > "Dmitry V. Levin" <ldv@altlinux.org> wrote: > > > > а не пора ли нам чего-нибудь придумать на тему установок > > > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > > > например очень бы хотелось этого для апача. > > > > PAM использовать нет никакой возможности? > > а как? я, возможно, туплю, но я не понимаю каким боком его тут > прикрутить. Таким же боком, которым я прикручивал PAM к crond. -- ldv [-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 12:26 ` Dmitry V. Levin @ 2006-08-23 13:10 ` Sergey Pinaev 2006-08-24 19:13 ` Dmitry V. Levin 0 siblings, 1 reply; 12+ messages in thread From: Sergey Pinaev @ 2006-08-23 13:10 UTC (permalink / raw) To: ALT Devel discussion list On Wed, 23 Aug 2006 16:26:47 +0400 "Dmitry V. Levin" <ldv@altlinux.org> wrote: > > > > а не пора ли нам чего-нибудь придумать на тему установок > > > > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > > > > например очень бы хотелось этого для апача. > > > > > > PAM использовать нет никакой возможности? > > > > а как? я, возможно, туплю, но я не понимаю каким боком его тут > > прикрутить. > > Таким же боком, которым я прикручивал PAM к crond. "вы не подскажете, где мы находимся?" "на воздушном шаре". я, конечно, понимаю, что rtfs - оно лучший ответ на любой вопрос. но, прежде чем rtfs, хотелось бы, в общих чертах, понять принцип "решения", чтобы понять - оно мне надо или нет. -- mail="Sergey Pinaev <dfo@antex.ru>" url="http://`echo $mail | sed 's/.* <\(.*\)@\(.*\)>/\1.\2/'`" ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 13:10 ` Sergey Pinaev @ 2006-08-24 19:13 ` Dmitry V. Levin 2006-08-25 6:26 ` Sergey Pinaev 2006-08-25 7:20 ` Sergey Vlasov 0 siblings, 2 replies; 12+ messages in thread From: Dmitry V. Levin @ 2006-08-24 19:13 UTC (permalink / raw) To: ALT Devel discussion list [-- Attachment #1: Type: text/plain, Size: 1247 bytes --] On Wed, Aug 23, 2006 at 05:10:28PM +0400, Sergey Pinaev wrote: > On Wed, 23 Aug 2006 16:26:47 +0400 > "Dmitry V. Levin" <ldv@altlinux.org> wrote: > > > > > > а не пора ли нам чего-нибудь придумать на тему установок > > > > > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > > > > > например очень бы хотелось этого для апача. > > > > > > > > PAM использовать нет никакой возможности? > > > > > > а как? я, возможно, туплю, но я не понимаю каким боком его тут > > > прикрутить. > > > > Таким же боком, которым я прикручивал PAM к crond. > > "вы не подскажете, где мы находимся?" "на воздушном шаре". > > я, конечно, понимаю, что rtfs - оно лучший ответ на любой вопрос. Более того, я полагаю, что vixie-cron-4.1.20040916-alt-pam.patch достаточно внятен, и при необходимости я могу прокомментировать. > но, прежде чем rtfs, хотелось бы, в общих чертах, понять принцип > "решения", чтобы понять - оно мне надо или нет. Грубо говоря, если код демона делает fork setuid [...] exit wait то после прикручивания PAM код демона делает pam_start pam_authenticate pam_acct_mgmt pam_open_session fork pam_setcred setuid [...] exit wait pam_close_session pam_end -- ldv [-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-24 19:13 ` Dmitry V. Levin @ 2006-08-25 6:26 ` Sergey Pinaev 2006-08-25 6:48 ` Alexey I. Froloff 2006-08-29 23:49 ` Michael Shigorin 2006-08-25 7:20 ` Sergey Vlasov 1 sibling, 2 replies; 12+ messages in thread From: Sergey Pinaev @ 2006-08-25 6:26 UTC (permalink / raw) To: ALT Devel discussion list On Thu, 24 Aug 2006 23:13:28 +0400 "Dmitry V. Levin" <ldv@altlinux.org> wrote: > то после прикручивания PAM код демона делает > pam_start угу, я так и думал. я не думаю, что миша возьмется за вкручивание такого в апач =) на мой взгляд вполне хватило бы установки лимитов заданых для непривилегированного пользователя перед запуском основного процесса. -- mail="Sergey Pinaev <dfo@antex.ru>" url="http://`echo $mail | sed 's/.* <\(.*\)@\(.*\)>/\1.\2/'`" ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-25 6:26 ` Sergey Pinaev @ 2006-08-25 6:48 ` Alexey I. Froloff 2006-08-29 23:49 ` Michael Shigorin 1 sibling, 0 replies; 12+ messages in thread From: Alexey I. Froloff @ 2006-08-25 6:48 UTC (permalink / raw) To: ALT Devel discussion list [-- Attachment #1: Type: text/plain, Size: 450 bytes --] * Sergey Pinaev <dfo@> [060825 10:28]: > на мой взгляд вполне хватило бы установки лимитов заданых > для непривилегированного пользователя перед запуском > основного процесса. Некая приблуда, которая выполняет session и выдаёт на stdout команды ulimit для шелла? -- Regards, Alexey I. Froloff AIF5-RIPN, AIF5-RIPE ------------------------------------------- Inform-Mobil, Ltd. System Administrator http://www.inform-mobil.ru/ [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 189 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-25 6:26 ` Sergey Pinaev 2006-08-25 6:48 ` Alexey I. Froloff @ 2006-08-29 23:49 ` Michael Shigorin 1 sibling, 0 replies; 12+ messages in thread From: Michael Shigorin @ 2006-08-29 23:49 UTC (permalink / raw) To: ALT Devel discussion list On Fri, Aug 25, 2006 at 10:26:51AM +0400, Sergey Pinaev wrote: > > то после прикручивания PAM код демона делает pam_start > угу, я так и думал. я не думаю, что миша возьмется за > вкручивание такого в апач =) на мой взгляд вполне хватило бы > установки лимитов заданых для непривилегированного пользователя > перед запуском основного процесса. Собсно я после твоего вопроса подумал с минутку в сторону ulimit, но пора было на паровоз собираться. Так и не додумал. -- ---- WBR, Michael Shigorin <mike@altlinux.ru> ------ Linux.Kiev http://www.linux.kiev.ua/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-24 19:13 ` Dmitry V. Levin 2006-08-25 6:26 ` Sergey Pinaev @ 2006-08-25 7:20 ` Sergey Vlasov 1 sibling, 0 replies; 12+ messages in thread From: Sergey Vlasov @ 2006-08-25 7:20 UTC (permalink / raw) To: ALT Devel discussion list [-- Attachment #1: Type: text/plain, Size: 574 bytes --] On Thu, Aug 24, 2006 at 11:13:28PM +0400, Dmitry V. Levin wrote: > Грубо говоря, если код демона делает > fork > setuid > [...] > exit > wait Насколько я понимаю, обычно демон как раз и не делает wait в этом месте. > то после прикручивания PAM код демона делает > pam_start > pam_authenticate > pam_acct_mgmt > pam_open_session > fork > pam_setcred > setuid > [...] > exit > wait > pam_close_session > pam_end Получается, что после прикручивания PAM придётся оставлять лишний процесс (причём под рутом) для выполнения pam_close_session. [-- Attachment #2: Type: application/pgp-signature, Size: 191 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 10:06 [devel] лимиты и "сервисы" Sergey Pinaev 2006-08-23 11:00 ` Dmitry V. Levin @ 2006-08-23 14:13 ` Alexey I. Froloff 2006-08-24 5:57 ` Sergey Pinaev 1 sibling, 1 reply; 12+ messages in thread From: Alexey I. Froloff @ 2006-08-23 14:13 UTC (permalink / raw) To: ALT Devel discussion list [-- Attachment #1: Type: text/plain, Size: 575 bytes --] * Sergey Pinaev <dfo@> [060823 14:07]: > а не пора ли нам чего-нибудь придумать на тему установок > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > например очень бы хотелось этого для апача. http://httpd.apache.org/docs/1.3/mod/core.html#rlimitcpu http://httpd.apache.org/docs/1.3/mod/core.html#rlimitmem http://httpd.apache.org/docs/1.3/mod/core.html#rlimitnproc -- Regards, Alexey I. Froloff AIF5-RIPN, AIF5-RIPE ------------------------------------------- Inform-Mobil, Ltd. System Administrator http://www.inform-mobil.ru/ [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 189 bytes --] ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [devel] лимиты и "сервисы" 2006-08-23 14:13 ` Alexey I. Froloff @ 2006-08-24 5:57 ` Sergey Pinaev 0 siblings, 0 replies; 12+ messages in thread From: Sergey Pinaev @ 2006-08-24 5:57 UTC (permalink / raw) To: ALT Devel discussion list On Wed, 23 Aug 2006 18:13:47 +0400 "Alexey I. Froloff" <raorn@immo.ru> wrote: > > а не пора ли нам чего-нибудь придумать на тему установок > > лимитов (как минимум) для сервисов, самостоятельно делающих setuid? > > например очень бы хотелось этого для апача. > http://httpd.apache.org/docs/1.3/mod/core.html#rlimitcpu > http://httpd.apache.org/docs/1.3/mod/core.html#rlimitmem > http://httpd.apache.org/docs/1.3/mod/core.html#rlimitnproc This applies to processes forked off from Apache children servicing requests, not the Apache children themselves. -- mail="Sergey Pinaev <dfo@antex.ru>" url="http://`echo $mail | sed 's/.* <\(.*\)@\(.*\)>/\1.\2/'`" ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2006-08-29 23:49 UTC | newest] Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2006-08-23 10:06 [devel] лимиты и "сервисы" Sergey Pinaev 2006-08-23 11:00 ` Dmitry V. Levin 2006-08-23 12:04 ` Sergey Pinaev 2006-08-23 12:26 ` Dmitry V. Levin 2006-08-23 13:10 ` Sergey Pinaev 2006-08-24 19:13 ` Dmitry V. Levin 2006-08-25 6:26 ` Sergey Pinaev 2006-08-25 6:48 ` Alexey I. Froloff 2006-08-29 23:49 ` Michael Shigorin 2006-08-25 7:20 ` Sergey Vlasov 2006-08-23 14:13 ` Alexey I. Froloff 2006-08-24 5:57 ` Sergey Pinaev
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