2011/08/11

Дабы больше не лазить по закромам родины

/etc/default/keyborard
[+] # Ну не могу я уже без этого ...
[-] XKBOPTIONS="..."
[+] XKBOPTIONS="[...],ctrl:nocaps"

$ sudo dpgk-reconfigure console-setup

Update:
How to permanently disable 'Pointer can be controlled using the keypad' function:
/usr/share/X11/xkb/compat/complete
[-] augment "mousekeys"
[-] augment "accessx(full)"
[+] //augment "mousekeys"
[+] //augment "accessx(full)"

Update2:
Disable touchpad while typing
syndaemon -i 1 [-d]

Update++:
... network service discovery disabled ...
/etc/default/avahi-daemon
[-] AVAHI_DAEMON_DETECT_LOCAL=1
[+] AVAHI_DAEMON_DETECT_LOCAL=0
++, а то каждый раз...
#!/bin/bash
#Exit on any error
set -e
#Trusted network definition
TRUSTED_NETWORK="192.168.1.0/24"
TORRENT_PORT="51000"
#Try to use a nice format
E="echo -e -n"
T="\t"
OK="${T}[Ok]\n"
${E} "Cleaning up iptables..."
iptables -F
iptables -X
iptables -t nat -F
iptables -t nat -X
iptables -t mangle -F
iptables -t mangle -X
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
${E} ${T}${T}${T}${T}${T}${OK}
${E} "Accept anything from myself..."
iptables -A INPUT -s 127.0.0.1/32 --jump ACCEPT
${E} ${T}${T}${T}${T}${OK}
#${E} "Allow myself to be a non-passive FTP client..."
#iptables -A INPUT -p tcp --dport ftp-data --jump ACCEPT
#${E} ${T}${T}${OK}
${E} "Do not allow a local user to connect to a remote Telnet\n"
${E} "server and thus give away login and password information..."
iptables -A OUTPUT -p tcp --dport telnet --jump REJECT
${E} ${OK}
${E} "Accept SSH connections from ${TRUSTED_NETWORK}..."
iptables -A INPUT -s ${TRUSTED_NETWORK} -p tcp --dport ssh --jump ACCEPT
${E} ${T}${T}${OK}
${E} "Accept HTTP connections from ${TRUSTED_NETWORK}..."
iptables -A INPUT -s ${TRUSTED_NETWORK} -p tcp --dport http --jump ACCEPT
iptables -A INPUT -s ${TRUSTED_NETWORK} -p tcp --dport https --jump ACCEPT
${E} ${T}${T}${OK}
${E} "Accept torrent connections on port ${TORRENT_PORT}..."
iptables -A INPUT -p tcp --dport ${TORRENT_PORT} --jump ACCEPT
${E} ${T}${T}${OK}
${E} "Block connection attempts to priveleged TCP and UDP ports..."
iptables -A INPUT -p tcp --dport 1:1023 --jump REJECT
iptables -A INPUT -p udp --dport 1:1023 --jump REJECT
${E} ${OK}
${E} "Allow to be a client...."
iptables -A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
${E} ${T}${T}${T}${T}${OK}
${E} "Drop inbound TCP packets with ICMP messages..."
iptables -A INPUT -p tcp --jump REJECT
${E} ${T}${T}${OK}
${E} "\nFirewall rules installed:\n"
iptables -L

iptables-save > /etc/iptables.up.rules
/etc/rc.local:
[+] IPTABLES_RULES="/etc/iptables.up.rules"
[+] if [-f ${IPTABLES_RULES}]; then
[+] iptables-restore < ${IPTABLES_RULES}
{+] fi

2 comments:

SelfChief said...

Я так понимаю вы убрали эффект капс-лока? )

dmi3s said...

КапсЛок будет работать как контрол. Emacs использую редко, но привык все сочетания на левую руку делать через капс.