View previous topic :: View next topic |
Author |
Message |
gbetous l33t
![l33t l33t](/images/ranks/rank_rect_4.gif)
![](images/avatars/21420982144ec733b976c9.jpg)
Joined: 15 Jan 2004 Posts: 679 Location: Toulouse
|
Posted: Sat Feb 06, 2010 12:25 pm Post subject: [Portage] Quel profile pour un serveur domestique ? |
|
|
Bonjour,
J'ai un serveur à la maison qui me sert de routeur/firewall/serveur de fichiers. Bref mon unique truc allumé 24h/24 (ou presque [*]) qui me sert un peu à tout.
Jusque là j'utilisais le profile "server", qui me permet d'avoir qques options par défaut plus adaptées, notamment l'absence de X.
Seulement depuis... heu... longtemps en fait, j'ai un avertissement comme quoi je devrais plutot passer à "hardened".
Sans trop savoir pourquoi, ce profile me fait un peu peur, et j'ai toujours hésité à l'utiliser.
D'où ma question : quel profile utilisez-vous dans des circonstances similaires ? Pourquoi ? Que me conseillez-vous ? Et sinon, ça boume ?
Merci ![Wink :wink:](images/smiles/icon_wink.gif) _________________ Core2Quad Q6600
ASUS P5B-V (i965 video intégrée)
~amd64 / KDE
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
guilc Bodhisattva
![Bodhisattva Bodhisattva](/images/ranks/rank-bodhisattva.gif)
![](images/avatars/190892864153fcc64a2a920.jpg)
Joined: 15 Nov 2003 Posts: 3326 Location: Paris - France
|
Posted: Sat Feb 06, 2010 1:18 pm Post subject: |
|
|
Serveur @home :
Code: | # eselect profile list
Available profile symlink targets:
[1] default/linux/x86/10.0
[2] default/linux/x86/10.0/desktop
[3] default/linux/x86/10.0/developer
[4] default/linux/x86/10.0/server
[5] hardened/linux/x86/10.0 *
[6] selinux/2007.0/x86
[7] selinux/2007.0/x86/hardened
[8] selinux/v2refpolicy/x86
[9] selinux/v2refpolicy/x86/desktop
[10] selinux/v2refpolicy/x86/developer
[11] selinux/v2refpolicy/x86/hardened
[12] selinux/v2refpolicy/x86/server
|
Pourquoi cela ferait peur ?
C'est ni plus ni moins que la même chose, avec en plus des patchs pour la libc, gcc, et le noyau pour renforcer la sécurité du système et parrer des attaques classiques. Ensuite, tu n'es pas forcé d'utiliser les systèmes RBAC/RSBAC fournis par grsec/selinux (il faut bien avouer que ces systèmes, quoique efficaces, sont très complexe à administrer de manière efficace)
Par contre, pour le passage d'un profil non-hardened à un profil hardened, il faut réinstaller à partir d'une toolchain hardened propre... _________________ Merci de respecter les règles du forum.
Mon site perso : https://www.xwing.info
Mon PORTDIR_OVERLAY : https://gentoo.xwing.info ou layman -a xwing |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
gbetous l33t
![l33t l33t](/images/ranks/rank_rect_4.gif)
![](images/avatars/21420982144ec733b976c9.jpg)
Joined: 15 Jan 2004 Posts: 679 Location: Toulouse
|
Posted: Sat Feb 06, 2010 3:10 pm Post subject: |
|
|
Bon, je vais donc aller sur dur "hardened" je pense
QUand tu dis "pour le passage d'un profil non-hardened à un profil hardened, il faut réinstaller à partir d'une toolchain hardened propre", je suppose qu'il va me falloir prévoir le coup à l'avance : est-ce que passer en hardened, puis emerger 2 fois "system" est suffisant ? _________________ Core2Quad Q6600
ASUS P5B-V (i965 video intégrée)
~amd64 / KDE
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
d2_racing Bodhisattva
![Bodhisattva Bodhisattva](/images/ranks/rank-bodhisattva.gif)
![](images/avatars/1190120345458c61e31ec3c.jpg)
Joined: 25 Apr 2005 Posts: 13047 Location: Ste-Foy,Canada
|
Posted: Sun Feb 07, 2010 5:37 am Post subject: |
|
|
guilc wrote: |
C'est ni plus ni moins que la même chose, avec en plus des patchs pour la libc, gcc, et le noyau pour renforcer la sécurité du système et parrer des attaques classiques. |
Peux-tu élaborer plus au sujet du noyau et la sécurité entourant le hardening et surtout les attaques classiques.
La seule doc que je connais sur le sujet c'est ici : http://www.gentoo.org/proj/en/hardened/ |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
gbetous l33t
![l33t l33t](/images/ranks/rank_rect_4.gif)
![](images/avatars/21420982144ec733b976c9.jpg)
Joined: 15 Jan 2004 Posts: 679 Location: Toulouse
|
Posted: Sun Feb 07, 2010 9:59 am Post subject: |
|
|
Je m'auto-répond grâce à cette page :
Code: |
# emerge --oneshot binutils gcc virtual/libc
# emerge -e world
|
_________________ Core2Quad Q6600
ASUS P5B-V (i965 video intégrée)
~amd64 / KDE
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
guilc Bodhisattva
![Bodhisattva Bodhisattva](/images/ranks/rank-bodhisattva.gif)
![](images/avatars/190892864153fcc64a2a920.jpg)
Joined: 15 Nov 2003 Posts: 3326 Location: Paris - France
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
guilc Bodhisattva
![Bodhisattva Bodhisattva](/images/ranks/rank-bodhisattva.gif)
![](images/avatars/190892864153fcc64a2a920.jpg)
Joined: 15 Nov 2003 Posts: 3326 Location: Paris - France
|
Posted: Sun Feb 07, 2010 10:05 am Post subject: |
|
|
gbetous au fait :
Si tu veux un noyau patché récent (ainsi que quelques patches en test avant introduction dans portage) => layman -a hardened-development ![Wink ;)](images/smiles/icon_wink.gif) _________________ Merci de respecter les règles du forum.
Mon site perso : https://www.xwing.info
Mon PORTDIR_OVERLAY : https://gentoo.xwing.info ou layman -a xwing |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
d2_racing Bodhisattva
![Bodhisattva Bodhisattva](/images/ranks/rank-bodhisattva.gif)
![](images/avatars/1190120345458c61e31ec3c.jpg)
Joined: 25 Apr 2005 Posts: 13047 Location: Ste-Foy,Canada
|
Posted: Sun Feb 07, 2010 3:49 pm Post subject: |
|
|
merci guilc, je vais lire attentivement sur le sujet ![Razz :P](images/smiles/icon_razz.gif) |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
jaypeche Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
Joined: 13 Jun 2007 Posts: 176 Location: France
|
Posted: Sat Feb 13, 2010 12:03 pm Post subject: |
|
|
Salut,
Pour ton utilisation je confirme ton choix, qui me semble être un bon compromis ! Il faut savoir qu'au dessus d'hardened tu peux avoir du SeLinux, mais la ca devient vraiment trop "secure" et tu risques de rencontrer qq souçis...
Pour info, voiçi ma config pour un serveur réalisant les mêmes fonctions que le tien (Apache2, Squid, Samba, Vhosts, SSh, Netfilter, SQL...) :
Kernel :
Code: | pingwho ~ # uname -a
Linux pingwho 2.6.28-hardened-r9 #1 SMP Mon Oct 12 03:06:41 CEST 2009 i686 Intel(R) Celeron(TM) CPU 1200MHz GenuineIntel GNU/Linux |
Profile :
Code: | pingwho ~ # eselect profile list
Available profile symlink targets:
[1] default/linux/x86/10.0
[2] default/linux/x86/10.0/desktop
[3] default/linux/x86/10.0/developer
[4] default/linux/x86/10.0/server
[5] hardened/linux/x86/10.0 *
[6] selinux/2007.0/x86
[7] selinux/2007.0/x86/hardened
[8] selinux/v2refpolicy/x86
[9] selinux/v2refpolicy/x86/desktop
[10] selinux/v2refpolicy/x86/developer
[11] selinux/v2refpolicy/x86/hardened
[12] selinux/v2refpolicy/x86/server
|
Uptime :
Code: | pingwho ~ # uptime
13:02:22 up 119 days, 22:35, 2 users, load average: 0.46, 0.15, 0.05 |
RAID 10 :
Code: | pingwho ~ # cat /proc/mdstat
Personalities : [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md1 : active raid1 hdc1[1] hda1[0]
98176 blocks [2/2] [UU]
md3 : active raid1 hdc3[1] hda3[0]
500352 blocks [2/2] [UU]
md4 : active raid1 hdc4[1] hda4[0]
73625792 blocks [2/2] [UU]
md2 : active raid1 hdc2[1] hda2[0]
3906432 blocks [2/2] [UU]
unused devices: <none>
|
LVM :
Code: | pingwho ~ # mount -ls
/dev/md2 on / type ext3 (rw,noatime) [sys]
proc on /proc type proc (rw,nosuid,nodev,noexec)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec)
udev on /dev type tmpfs (rw,nosuid,size=10240k,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,gid=5,mode=620)
/dev/mapper/vg-usr on /usr type ext3 (rw,noatime) [usr]
/dev/mapper/vg-portage on /usr/portage type ext3 (rw,noatime) [portage]
/dev/mapper/vg-distfiles on /usr/portage/distfiles type ext3 (rw,noatime) [distfiles]
/dev/mapper/vg-var on /var type ext3 (rw,noatime) [var]
/dev/mapper/vg-www on /var/www type ext3 (rw,noatime) [www]
/dev/mapper/vg-tmp on /tmp type ext3 (rw,noatime) [tmp]
/dev/mapper/vg-home on /home type ext3 (rw,noatime) [home]
/dev/mapper/vg-data on /data type ext3 (rw,noatime) [data]
/dev/mapper/vg-opt on /opt type ext3 (rw,noatime) [opt]
shm on /dev/shm type tmpfs (rw,noexec,nosuid,nodev)
usbfs on /proc/bus/usb type usbfs (rw,noexec,nosuid,devmode=0664,devgid=85)
securityfs on /sys/kernel/security type securityfs (rw,noexec,nosuid,nodev)
|
Liens utiles :
* http://www.gentoo.org/proj/fr/hardened/primer.xml
* http://www.gentoo.org/doc/fr/gentoo-x86+raid+lvm2-quickinstall.xml
* http://www.gentoo.org/doc/fr/security/security-handbook.xml?part=1&chap=1
* http://pingwho.homelinux.org/pub/gentoo/ftp/packages/net-firewall/firewall-jay/
Personnellent, je suis très satisfait par cette configuration, Hardened patché GrSecurity est particulièrement fiable !
++ _________________
Gentoo Linux Rullez ! |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|