KVM: differenze tra le versioni

Da EigenWiki.
Vai alla navigazione Vai alla ricerca
(Creata pagina con "KVM è un'infrastruttura di virtualizzazione del kernel Linux. KVM attualmente supporta una completa virtualizzazione usando Intel VT o AMD-V Configurazione: 100GB disco qcow...")
 
m (subcat++ Config)
 
(5 versioni intermedie di un altro utente non mostrate)
Riga 1: Riga 1:
KVM è un'infrastruttura di virtualizzazione del kernel Linux. KVM attualmente supporta una completa virtualizzazione usando Intel VT o AMD-V
KVM è un'infrastruttura di virtualizzazione del kernel Linux. KVM attualmente supporta una completa virtualizzazione usando Intel VT o AMD-V


Configurazione:
100GB disco qcow2 e 1GB swap, rete bridge breig0, server VNC (non interferisce con le regole di iptables in basso), dispositivo RNG /dev/random, processore opteron_g3, <emulator> /usr/bin/kvm


tasksel:
= Configurazione =
--- ambiente desktop, --- server di stampa, +++ server ssh
20GB disco qcow2 e 1GB swap, rete bridge breig0, server VNC (non interferisce con le regole di iptables in basso), dispositivo RNG /dev/random, processore opteron_g3, <emulator> /usr/bin/kvm<br />


apt-get install htop iotop jnettop git p7zip lynis colordiff tmux wipe netcat-openbsd tcpdump iperf w3m pv nmap zerofree iputils-tracepath parted logcheck mosh rsync mtr-tiny curl command-not-found checksecurity debsums rkhunter clamav snoopy build-essential checkinstall cmake dpkg-dev diffutils monkeysphere iptables-persistent vim fdupes ssmtp


software per log e sicurezza: Possono essere configurati per mandare mail, per ora scrivono in /var/log/ e in /var/mail/eigen
==Tasksel==
logcheck: scrive un riassunto dei log, cercando di eliminare tutte le righe inutili.
--- ambiente desktop, --- server di stampa, +++ server ssh<br />
checksecurity: fa una serie di controlli su problemi di sicurezza comuni
tiger: controlla la configurazione del sistema alla ricerca di problemi
rkhunter: cerca rootkit sul sitema
unhide: cerca processi nascosti
debsums: controlla gli hash di tutti i pacchetti installati (binari e file di configurazione)
clamav: antivirus
snoopy: logga tutte le execve() con syslog VIVA LA PARANOIA!! :D


<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
aptitude install htop iotop jnettop git p7zip lynis colordiff tmux wipe netcat-openbsd tcpdump iperf w3m pv nmap zerofree iputils-tracepath parted mosh rsync mtr-tiny curl command-not-found checksecurity debsums rkhunter clamav build-essential checkinstall cmake dpkg-dev diffutils monkeysphere iptables-persistent vim fdupes ssmtp console-data debian-goodies ntp
</pre>


alcuni sono pesanti ed è inutile farli girare sempre
==Software per log e sicurezza==
Possono essere configurati per mandare mail, per ora scrivono in /var/log/ e in /var/mail/eigen
* checksecurity: fa una serie di controlli su problemi di sicurezza comuni
* tiger: controlla la configurazione del sistema alla ricerca di problemi
* rkhunter: cerca rootkit sul sitema
* unhide: cerca processi nascosti
* debsums: controlla gli hash di tutti i pacchetti installati (binari e file di configurazione)
* clamav: antivirus
 
Alcuni sono pesanti ed è inutile farli girare sempre<br />
 
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
chmod -x /etc/cron.daily/tripwire
chmod -x /etc/cron.daily/tripwire
chmod +x /etc/cron.d/logcheck
</pre>
 


Per aggiornare i pacchetti
==Aggiornare i pacchetti==
apt-get update && aptitude full-upgrade
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
aptitude update && aptitude full-upgrade
</pre>


Per aggiornare la cache di apt-file e command-not-found
Per aggiornare la cache di apt-file e command-not-found
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
apt-file update
apt-file update
update-command-not-found
update-command-not-found
</pre>
= Dopo aver clonato =
'''bisogna modificare questi file'''
* /etc/network/interfaces ''(cambiare ip)''
* /etc/hostname ''(aggiornare hostname)''
* /etc/hosts
e per evitare che tutte le chiavi del server ssh siano uguali
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
rm /etc/ssh/ssh_host_* && dpkg-reconfigure openssh-server
</pre>
==Installare monkeysphere==
Inserire, uno per riga, gli id delle chiavi [[PGP]] da autorizzare (es. ''Tizio <tizio@eigenlab.org>'').
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
mkdir .monkeysphere
nano .monkeysphere/authorized_user_ids
</pre>
Impostare il certificatore, ovvero la chiave che deve firmare tutte le chiavi in ''authorized_user_ids'' affinchè queste possano accedere. È necessario inserire la fingerprint completa (senza spazi) e non l'ID composto da 8 cifre.
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
monkeysphere-authentication c+ CHIAVE
</pre>
Aggiornare la lista delle chiavi autorizzate in modo che gli utenti inseriti possano accedere al server
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
monkeysphere-authentication update-users
</pre>
==Iptables==
Iptables è configurato in modo da droppare tutto il traffico in ingresso ad eccezione di ssh. Le regole caricate all'avvio del sistema si trovano in /etc/iptables/rules.v4 per ipv4 e /etc/iptables/rules.v6 per ipv6.


Per aprire un'altra porta si usano i comandi
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
iptables -A INPUT -p tcp -m tcp --dport PORTA -m state --state NEW -j ACCEPT
ip6tables -A INPUT -p tcp -m tcp --dport PORTA -m state --state NEW -j ACCEPT
</pre>


Modifiche ai file di configurazione:
E per rendere permanenti le regole impostate
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
iptables-save > /etc/iptables/rules.v4
ip6tables-save > /etc/iptables/rules.v6
</pre>


= Modifiche ai file di configurazione nelle VM =


/etc/rkhunter.conf
====/etc/rkhunter.conf====
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
#DISABLE_TESTS=suspscan hidden_procs deleted_files packet_cap_apps apps
#DISABLE_TESTS=suspscan hidden_procs deleted_files packet_cap_apps apps
DISABLE_TESTS=suspscan deleted_files packet_cap_apps apps
DISABLE_TESTS=suspscan deleted_files packet_cap_apps apps
</pre>


 
====.bashrc====
.bashrc
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
export LS_OPTIONS='--color=auto'
export LS_OPTIONS='--color=auto'
eval "`dircolors`"
eval "`dircolors`"
Riga 70: Riga 117:
fi
fi
unset color_prompt force_color_prompt
unset color_prompt force_color_prompt
</pre>


 
====/etc/ssh/sshd_config====
/etc/ssh/sshd_config
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
AuthorizedKeysFile /var/lib/monkeysphere/authorized_keys/%u
AuthorizedKeysFile /var/lib/monkeysphere/authorized_keys/%u
PasswordAuthentication no
PasswordAuthentication no
</pre>
<br />
Per adesso c'è la chiave dei nodi. è da rimuovere dopo aver configurato monkeysphere (aggiungere i certificatori con "monkeysphere-authentication add-identity-certifier $fingerprint" e gli id autorizzati in .monkeysphere/authorized_user_ids)<br />


per adesso c'è la chiave dei nodi. è da rimuovere dopo aver configurato monkeysphere (aggiungere i certificatori con "monkeysphere-authentication add-identity-certifier $fingerprint" e gli id autorizzati in .monkeysphere/authorized_user_ids)
====/root/.ssh/authorized_keys====
/root/.ssh/authorized_keys
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCr+J+hhlUnYhKLOnW55aZhJrdHHSQU9XXoP0DcMuvIQ3+SYV6ZZJLMvcdN7puSdkcKiK9DEpsN8uCWfIsxu8LkWJfq6Q/DUBkwvXgKlpbisFaj82ucy7ioiZ1aEc6LMQ/VxG4iHCnGXjWqNLA9sB9lgVDXD29lm8n/i99DHNI8TLHzV9aXz3uR39IqvD4zFBZPSsoDvZ9BsOC6TIUl+Ua0lx1olJxwGawK9he52G55RHhMI+NYj5/wMp80kOhtzRN5F0wRt08Yv2Wu0Kx9akRJBOmI+CcfxxEk7Fcg/kCHG8evS4i4chSMBbBLjOhTk/+Q6nbT3TNIeG2LAtUpml2f node_key@eigenlab
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCr+J+hhlUnYhKLOnW55aZhJrdHHSQU9XXoP0DcMuvIQ3+SYV6ZZJLMvcdN7puSdkcKiK9DEpsN8uCWfIsxu8LkWJfq6Q/DUBkwvXgKlpbisFaj82ucy7ioiZ1aEc6LMQ/VxG4iHCnGXjWqNLA9sB9lgVDXD29lm8n/i99DHNI8TLHzV9aXz3uR39IqvD4zFBZPSsoDvZ9BsOC6TIUl+Ua0lx1olJxwGawK9he52G55RHhMI+NYj5/wMp80kOhtzRN5F0wRt08Yv2Wu0Kx9akRJBOmI+CcfxxEk7Fcg/kCHG8evS4i4chSMBbBLjOhTk/+Q6nbT3TNIeG2LAtUpml2f node_key@eigenlab
</pre>


/etc/monkeysphere/monkeysphere-authentication.conf
====/etc/monkeysphere/monkeysphere-authentication.conf====
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
LOG_LEVEL=DEBUG
LOG_LEVEL=DEBUG
RAW_AUTHORIZED_KEYS="%h/.ssh/authorized_keys"
RAW_AUTHORIZED_KEYS="%h/.ssh/authorized_keys"
</pre>


/etc/crontab
====/etc/crontab====
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
0  *    * * *  root    /usr/sbin/monkeysphere-authentication update-users &> /dev/null
0  *    * * *  root    /usr/sbin/monkeysphere-authentication update-users &> /dev/null
</pre>


 
====/etc/iptables/rules.v4====
/etc/cron.d/logcheck
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
mailto=""
 
/etc/iptables/rules.v4
# Generated by iptables-save v1.4.21 on Sat May  2 23:51:15 2015
*filter
*filter
:INPUT DROP [0:0]
:INPUT DROP [0:0]
:FORWARD DROP [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [38:3848]
:OUTPUT ACCEPT [1:176]
-A INPUT -i lo -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -p tcp -m tcp --dport 22 -m state --state NEW -j ACCEPT
 
-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -m conntrack --ctstate INVALID -j DROP
-A INPUT -p icmp -j ACCEPT
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
-A INPUT -j REJECT --reject-with icmp-port-unreachable
 
-A INPUT -p icmp --icmp-type destination-unreachable -j ACCEPT
-A INPUT -p icmp --icmp-type source-quench -j ACCEPT
-A INPUT -p icmp --icmp-type time-exceeded -j ACCEPT
-A INPUT -p icmp --icmp-type parameter-problem -j ACCEPT
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT
 
-A INPUT -p tcp --dport 22 -j ACCEPT
 
COMMIT
COMMIT
# Completed on Sat May  2 23:51:15 2015
</pre>


/etc/iptables/rules.v6
====/etc/iptables/rules.v6====
# Generated by ip6tables-save v1.4.21 on Sat May  2 23:51:15 2015
*filter
*filter
:INPUT DROP [2:200]
:INPUT DROP [0:0]
:FORWARD DROP [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [1:93]
:OUTPUT ACCEPT [0:0]
 
-A INPUT -i lo -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -p tcp -m tcp --dport 22 -m state --state NEW -j ACCEPT
 
-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -m rt --rt-type 0 -j DROP
-A INPUT -p icmp -j ACCEPT
 
-A INPUT -j REJECT --reject-with icmp6-port-unreachable
-A INPUT -p icmpv6 --icmpv6-type neighbor-solicitation -m hl --hl-eq 255 -j ACCEPT
-A INPUT -p icmpv6 --icmpv6-type neighbor-advertisement -m hl --hl-eq 255 -j ACCEPT
 
-A INPUT -s fe80::/10 -p icmpv6 --icmpv6-type echo-reply -j ACCEPT
-A INPUT -m conntrack --ctstate INVALID -j DROP
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
 
-A INPUT -p icmpv6 --icmpv6-type destination-unreachable -j ACCEPT
-A INPUT -p icmpv6 --icmpv6-type packet-too-big -j ACCEPT
-A INPUT -p icmpv6 --icmpv6-type time-exceeded -j ACCEPT
-A INPUT -p icmpv6 --icmpv6-type parameter-problem -j ACCEPT
-A INPUT -p icmpv6 --icmpv6-type echo-request -j ACCEPT
 
-A INPUT -p tcp --dport 22 -j ACCEPT
 
COMMIT
COMMIT
# Completed on Sat May  2 23:51:15 2015
</pre>


/etc/resolv.conf
====/etc/resolv.conf====
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
domain eigenlab.org
domain eigenlab.org
search eigenlab.org  
search eigenlab.org  
nameserver 10.174.0.100
nameserver 10.174.0.100
nameserver 10.174.0.101
nameserver 10.174.0.101
</pre>




/etc/network/interfaces
====/etc/network/interfaces====
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
auto lo
auto lo
iface lo inet loopback
iface lo inet loopback
Riga 138: Riga 215:
         address 10.175.1.33
         address 10.175.1.33
         netmask 255.254.0.0
         netmask 255.254.0.0
         gateway 10.175.133.1
         gateway 10.175.0.1


iface eth0 inet6 static
iface eth0 inet6 static
         address 2a00:1508:1:f010::1:33
         address 2a00:1508:1:f010::1:33
         netmask 64
         netmask 64
         gateway 2a00:1508:1:f010::101
         gateway 2a00:1508:1:f010::1
</pre>


 
====/etc/pam.d/su====
/etc/pam.d/su
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
auth      required  pam_wheel.so
auth      required  pam_wheel.so
</pre>


 
====/etc/ssmtp/ssmtp.conf====
/etc/ssmtp/ssmtp.conf  
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
#
#
# Config file for sSMTP sendmail
# Config file for sSMTP sendmail
Riga 179: Riga 258:
AuthUser=tuttisuitetti@eigenlab.org
AuthUser=tuttisuitetti@eigenlab.org
AuthPass=Passw0rd
AuthPass=Passw0rd
</pre>




Dopo aver clonato la macchina base bisogna modificare questi file
[[Categoria:Config]]
/etc/network/interfaces cambiare ip
/etc/hostname aggiornare hostname
/etc/hosts
rm /etc/ssh/ssh_host_* && dpkg-reconfigure openssh-server Per evitare che tutte le chiavi siano uguali

Versione attuale delle 03:03, 28 ago 2017

KVM è un'infrastruttura di virtualizzazione del kernel Linux. KVM attualmente supporta una completa virtualizzazione usando Intel VT o AMD-V


Configurazione

20GB disco qcow2 e 1GB swap, rete bridge breig0, server VNC (non interferisce con le regole di iptables in basso), dispositivo RNG /dev/random, processore opteron_g3, <emulator> /usr/bin/kvm


Tasksel

--- ambiente desktop, --- server di stampa, +++ server ssh

aptitude install htop iotop jnettop git p7zip lynis colordiff tmux wipe netcat-openbsd tcpdump iperf w3m pv nmap zerofree iputils-tracepath parted mosh rsync mtr-tiny curl command-not-found checksecurity debsums rkhunter clamav build-essential checkinstall cmake dpkg-dev diffutils monkeysphere iptables-persistent vim fdupes ssmtp console-data debian-goodies ntp

Software per log e sicurezza

Possono essere configurati per mandare mail, per ora scrivono in /var/log/ e in /var/mail/eigen

  • checksecurity: fa una serie di controlli su problemi di sicurezza comuni
  • tiger: controlla la configurazione del sistema alla ricerca di problemi
  • rkhunter: cerca rootkit sul sitema
  • unhide: cerca processi nascosti
  • debsums: controlla gli hash di tutti i pacchetti installati (binari e file di configurazione)
  • clamav: antivirus

Alcuni sono pesanti ed è inutile farli girare sempre

chmod -x /etc/cron.daily/tripwire

Aggiornare i pacchetti

aptitude update && aptitude full-upgrade

Per aggiornare la cache di apt-file e command-not-found

apt-file update
update-command-not-found

Dopo aver clonato

bisogna modificare questi file

  • /etc/network/interfaces (cambiare ip)
  • /etc/hostname (aggiornare hostname)
  • /etc/hosts

e per evitare che tutte le chiavi del server ssh siano uguali

rm /etc/ssh/ssh_host_* && dpkg-reconfigure openssh-server

Installare monkeysphere

Inserire, uno per riga, gli id delle chiavi PGP da autorizzare (es. Tizio <tizio@eigenlab.org>).

mkdir .monkeysphere
nano .monkeysphere/authorized_user_ids

Impostare il certificatore, ovvero la chiave che deve firmare tutte le chiavi in authorized_user_ids affinchè queste possano accedere. È necessario inserire la fingerprint completa (senza spazi) e non l'ID composto da 8 cifre.

monkeysphere-authentication c+ CHIAVE

Aggiornare la lista delle chiavi autorizzate in modo che gli utenti inseriti possano accedere al server

monkeysphere-authentication update-users

Iptables

Iptables è configurato in modo da droppare tutto il traffico in ingresso ad eccezione di ssh. Le regole caricate all'avvio del sistema si trovano in /etc/iptables/rules.v4 per ipv4 e /etc/iptables/rules.v6 per ipv6.

Per aprire un'altra porta si usano i comandi

iptables -A INPUT -p tcp -m tcp --dport PORTA -m state --state NEW -j ACCEPT
ip6tables -A INPUT -p tcp -m tcp --dport PORTA -m state --state NEW -j ACCEPT

E per rendere permanenti le regole impostate

iptables-save > /etc/iptables/rules.v4
ip6tables-save > /etc/iptables/rules.v6

Modifiche ai file di configurazione nelle VM

/etc/rkhunter.conf

#DISABLE_TESTS=suspscan hidden_procs deleted_files packet_cap_apps apps
DISABLE_TESTS=suspscan deleted_files packet_cap_apps apps

.bashrc

export LS_OPTIONS='--color=auto'
eval "`dircolors`"
alias ls='ls $LS_OPTIONS'
alias ll='ls $LS_OPTIONS -l'
alias l='ls $LS_OPTIONS -lA'

HISTSIZE=500000
HISTFILESIZE=500000000

force_color_prompt=yes

if [ -n "$force_color_prompt" ]; then
    if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
        # We have color support; assume it's compliant with Ecma-48
        # (ISO/IEC-6429). (Lack of such support is extremely rare, and such
        # a case would tend to support setf rather than setaf.)
        color_prompt=yes
    else
        color_prompt=
    fi
fi

if [ "$color_prompt" = yes ]; then
    PS1='${debian_chroot:+($debian_chroot)}\[\033[01;31m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
    PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt

/etc/ssh/sshd_config

AuthorizedKeysFile /var/lib/monkeysphere/authorized_keys/%u
PasswordAuthentication no


Per adesso c'è la chiave dei nodi. è da rimuovere dopo aver configurato monkeysphere (aggiungere i certificatori con "monkeysphere-authentication add-identity-certifier $fingerprint" e gli id autorizzati in .monkeysphere/authorized_user_ids)

/root/.ssh/authorized_keys

ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCr+J+hhlUnYhKLOnW55aZhJrdHHSQU9XXoP0DcMuvIQ3+SYV6ZZJLMvcdN7puSdkcKiK9DEpsN8uCWfIsxu8LkWJfq6Q/DUBkwvXgKlpbisFaj82ucy7ioiZ1aEc6LMQ/VxG4iHCnGXjWqNLA9sB9lgVDXD29lm8n/i99DHNI8TLHzV9aXz3uR39IqvD4zFBZPSsoDvZ9BsOC6TIUl+Ua0lx1olJxwGawK9he52G55RHhMI+NYj5/wMp80kOhtzRN5F0wRt08Yv2Wu0Kx9akRJBOmI+CcfxxEk7Fcg/kCHG8evS4i4chSMBbBLjOhTk/+Q6nbT3TNIeG2LAtUpml2f node_key@eigenlab

/etc/monkeysphere/monkeysphere-authentication.conf

LOG_LEVEL=DEBUG
RAW_AUTHORIZED_KEYS="%h/.ssh/authorized_keys"

/etc/crontab

0  *    * * *   root    /usr/sbin/monkeysphere-authentication update-users &> /dev/null

/etc/iptables/rules.v4

*filter
:INPUT DROP [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [1:176]
-A INPUT -i lo -j ACCEPT

-A INPUT -m conntrack --ctstate INVALID -j DROP
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT

-A INPUT -p icmp --icmp-type destination-unreachable -j ACCEPT
-A INPUT -p icmp --icmp-type source-quench -j ACCEPT
-A INPUT -p icmp --icmp-type time-exceeded -j ACCEPT
-A INPUT -p icmp --icmp-type parameter-problem -j ACCEPT
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT

-A INPUT -p tcp --dport 22 -j ACCEPT

COMMIT

/etc/iptables/rules.v6

  • filter
INPUT DROP [0:0]
FORWARD DROP [0:0]
OUTPUT ACCEPT [0:0]

-A INPUT -i lo -j ACCEPT

-A INPUT -m rt --rt-type 0 -j DROP

-A INPUT -p icmpv6 --icmpv6-type neighbor-solicitation -m hl --hl-eq 255 -j ACCEPT -A INPUT -p icmpv6 --icmpv6-type neighbor-advertisement -m hl --hl-eq 255 -j ACCEPT

-A INPUT -s fe80::/10 -p icmpv6 --icmpv6-type echo-reply -j ACCEPT -A INPUT -m conntrack --ctstate INVALID -j DROP -A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT

-A INPUT -p icmpv6 --icmpv6-type destination-unreachable -j ACCEPT -A INPUT -p icmpv6 --icmpv6-type packet-too-big -j ACCEPT -A INPUT -p icmpv6 --icmpv6-type time-exceeded -j ACCEPT -A INPUT -p icmpv6 --icmpv6-type parameter-problem -j ACCEPT -A INPUT -p icmpv6 --icmpv6-type echo-request -j ACCEPT

-A INPUT -p tcp --dport 22 -j ACCEPT

COMMIT

/etc/resolv.conf

domain eigenlab.org
search eigenlab.org 
nameserver 10.174.0.100
nameserver 10.174.0.101


/etc/network/interfaces

auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
#iface eth0 inet dhcp

auto eth0
iface eth0 inet static
        address 10.175.1.33
        netmask 255.254.0.0
        gateway 10.175.0.1

iface eth0 inet6 static
        address 2a00:1508:1:f010::1:33
        netmask 64
        gateway 2a00:1508:1:f010::1

/etc/pam.d/su

auth       required   pam_wheel.so

/etc/ssmtp/ssmtp.conf

#
# Config file for sSMTP sendmail
#
# The person who gets all mail for userids < 1000
# Make this empty to disable rewriting.
root=tuttisuitetti@eigenlab.org

# The place where the mail goes. The actual machine name is required no 
# MX records are consulted. Commonly mailhosts are named mail.domain.com
mailhub=mail.gandi.net:587

# Where will the mail seem to come from?
#rewriteDomain=

# The full hostname
hostname=eigenlab.org

# Are users allowed to set their own From: address?
# YES - Allow the user to specify their own From: address
# NO - Use the system generated From: address
#FromLineOverride=YES


UseTLS=YES
UseSTARTTLS=YES
rewriteDomain=eigenlab.org
AuthUser=tuttisuitetti@eigenlab.org
AuthPass=Passw0rd