ALT Linux Community general discussions
 help / color / mirror / Atom feed
* [Comm]  Server 4.0 + squid + pam_auth
@ 2007-11-13  7:15 Vitalik Salomatin
    0 siblings, 1 reply; 4+ messages in thread
From: Vitalik Salomatin @ 2007-11-13  7:15 UTC (permalink / raw)
  To: community

Раскоментировать в  /etc/httpd/conf/httpd.conf

LoadModule digest_auth_module modules/mod_auth_digest.so
AddModule mod_auth_digest.c
сохранить

в самый конец вставить 

<Directory /var/www/html/admin>
    AuthType Digest
    AuthName CHEL # любое слово
    AuthDigestFile "/var/www/auth/digest-password"
    require	user vova pavel 

</Directory>

сохранить и перезапустить  apache

В squid  найти эти места и вствить

#Recommended minimum configuration:

auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/passwd
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
auth_param basic credentialsttl 2 hours
auth_param basic casesensitive off

#Recommended minimum configuration:

acl Safe_ports port 591         # filemaker
acl Safe_ports port 777         # multiling http
acl CONNECT method CONNECT
acl control proxy_auth REQUIRED ######## вставить

#пример для адреса 
acl zvezd32 src 10.0.0.32
acl zvezd proxy_auth vova
http_access allow zvezd32 zvezd control


Добавить первого полдьзвателя с ключем -c

[root@localhost root]# htdigest -c /var/www/auth/digest-password CHEL vova
Adding password for vova in realm CHEL
New password:  "ввевти пароль"
Re-type new password:  "повторить"
[root@localhost root]#

Добавление нового пользователя без указания ключа -c , иначе файл будет очищен

[root@localhost root]# htdigest /var/www/auth/digest-password CHEL pavel
Adding user pavel in realm CHEL
New password:
Re-type new password:
Если что то еще и дать команду
updatedb (преобразование файловой системы для индефикации)

У меня так работает.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Comm] Server 4.0 + squid + pam_auth
  @ 2007-11-15  8:56   ` Глодин С.В.
  2007-11-15 11:07     ` Serge
  0 siblings, 1 reply; 4+ messages in thread
From: Глодин С.В. @ 2007-11-15  8:56 UTC (permalink / raw)
  To: ALT Linux Community general discussions

вівторок, 13-лис-2007, Voffka Putinin написав:
> Виталий,
>
>   а при чём тут digest и ncsa? В теме же написано - pam_auth. Чтобы при
> создании пользователя он мог и по sftp заходить, и почтой пользоваться, и
> интернетом через прокси - и для этого не нужно было заводить разные пароли
> разными способами - а просто добавить юзера локального. Вот в чём задача...

$ cat /etc/pam.d/squid
auth required /lib/security/pam_stack.so service=system-auth
account required /lib/security/pam_stack.so service=system-auth

$ fgrep 'auth_param basic' /etc/squid/squid.conf
auth_param basic program /usr/lib/squid/pam_auth
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
auth_param basic credentialsttl 2 hours
auth_param basic casesensitive on

$ stat /usr/lib/squid/pam_auth
  File: `/usr/lib/squid/pam_auth'
  Size: 10496           Blocks: 24         IO Block: 4096   regular file
Device: 801h/2049d      Inode: 3769639     Links: 1
Access: (4755/-rwsr-xr-x)  Uid: (    0/    root)   Gid: (   27/    auth)

-- 
С уважением,
               С.В. Глодин



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Comm] Server 4.0 + squid + pam_auth
  2007-11-15  8:56   ` Глодин С.В.
@ 2007-11-15 11:07     ` Serge
  2007-11-15 17:28       ` Глодин С.В.
  0 siblings, 1 reply; 4+ messages in thread
From: Serge @ 2007-11-15 11:07 UTC (permalink / raw)
  To: ALT Linux Community general discussions

В сообщении от Thursday 15 November 2007 10:56:25 Глодин С.В. написал(а):
> вівторок, 13-лис-2007, Voffka Putinin написав:
> > Виталий,
> >
> >   а при чём тут digest и ncsa? В теме же написано - pam_auth. Чтобы при
> > создании пользователя он мог и по sftp заходить, и почтой пользоваться, и
> > интернетом через прокси - и для этого не нужно было заводить разные
> > пароли разными способами - а просто добавить юзера локального. Вот в чём
> > задача...
>
> $ cat /etc/pam.d/squid
> auth required /lib/security/pam_stack.so service=system-auth
> account required /lib/security/pam_stack.so service=system-auth
>
> $ fgrep 'auth_param basic' /etc/squid/squid.conf
> auth_param basic program /usr/lib/squid/pam_auth
> auth_param basic children 5
> auth_param basic realm Squid proxy-caching web server
> auth_param basic credentialsttl 2 hours
> auth_param basic casesensitive on
>
> $ stat /usr/lib/squid/pam_auth
>   File: `/usr/lib/squid/pam_auth'
>   Size: 10496           Blocks: 24         IO Block: 4096   regular file
> Device: 801h/2049d      Inode: 3769639     Links: 1
> Access: (4755/-rwsr-xr-x)  Uid: (    0/    root)   Gid: (   27/    auth)
это рабочий вариант?


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Comm] Server 4.0 + squid + pam_auth
  2007-11-15 11:07     ` Serge
@ 2007-11-15 17:28       ` Глодин С.В.
  0 siblings, 0 replies; 4+ messages in thread
From: Глодин С.В. @ 2007-11-15 17:28 UTC (permalink / raw)
  To: ALT Linux Community general discussions

> > $ cat /etc/pam.d/squid
> > auth required /lib/security/pam_stack.so service=system-auth
> > account required /lib/security/pam_stack.so service=system-auth
> >
> > $ fgrep 'auth_param basic' /etc/squid/squid.conf
> > auth_param basic program /usr/lib/squid/pam_auth
> > auth_param basic children 5
> > auth_param basic realm Squid proxy-caching web server
> > auth_param basic credentialsttl 2 hours
> > auth_param basic casesensitive on
> >
> > $ stat /usr/lib/squid/pam_auth
> >   File: `/usr/lib/squid/pam_auth'
> >   Size: 10496           Blocks: 24         IO Block: 4096   regular file
> > Device: 801h/2049d      Inode: 3769639     Links: 1
> > Access: (4755/-rwsr-xr-x)  Uid: (    0/    root)   Gid: (   27/    auth)
>
> это рабочий вариант?

Да. Работает на 8 серверах. Правда, под Compact 3.0, но я не думаю, что под 
Server 4.0 сильно будет отличаться.

-- 
С уважением,
               С.В. Глодин



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-11-15 17:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-13  7:15 [Comm] Server 4.0 + squid + pam_auth Vitalik Salomatin
2007-11-15  8:56   ` Глодин С.В.
2007-11-15 11:07     ` Serge
2007-11-15 17:28       ` Глодин С.В.

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