View previous topic :: View next topic |
Author |
Message |
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Thu Mar 08, 2007 10:21 am Post subject: Iptables e aggiornamento documentazione ufficiale |
|
|
Ho ripreso in mano iptables perchè trovo la neccessità di fare il nat attraverso la porta ethernet del portatile ad un amico che non ha accesso ad una rete wifi.
Sto seguendo queste guide: http://www.gentoo.org/doc/en/home-router-howto.xml e http://gentoo-wiki.com/HOWTO_Iptables_for_newbies.
In particolare mi trovo a dover abilitare determinate opzioni del kernel.
Il kernel che utilizzo sono i gentoo-sources-2.6.20.r1che non hanno poi molto di diverso dai gentoo-sources-2.6.19-r5 (stabili) per quello che riguarda la configurazione di netfilter.
Il problema è che le opzioni di configurazione del kernel proposti nelle guide citate sono un tantino diverse da quelle che mi presenta il mio "make menuconfig" (non lapidatemi se ho detto una cazzata troppo grossa...!). Ad esempio, in questa, che è aggiornata a due settimane fa, non trovo la voce
Code: | ["enable"] Netfilter Xtables_Match_State, most firewall scripts use state...including the sample here. | .
Lascio a voi scoprire le differenze tra Home Route Howto, aggiornata a ieri, e quello che trovate nel vostro kernel.
Tutte le opzioni che abilito le compilo statiche, quindi non come modulo.
Quindi mi sono messo a leggere un pò tutte le opzioni che riguardano netfilter, ma ricompila, ricompila...ecc. il kernel alla fine mi mancava sempre qualche opzione abilitata.
Mi date una mano? _________________ LP |
|
Back to top |
|
|
crisandbea Veteran
Joined: 03 Jul 2005 Posts: 1778 Location: BOSCO (SA) ... ma domiciliato a Bologna....
|
Posted: Thu Mar 08, 2007 10:28 am Post subject: |
|
|
dovrebbe essere qua:
Code: |
Core Netfilter Configuration
│ Arrow keys navigate the menu. <Enter> selects submenus --->. Highlighted letters are hotkeys. │
│ Pressing <Y> includes, <N> excludes, <M> modularizes features. Press <Esc><Esc> to exit, <?> for Help, │
│ </> for Search. Legend: [*] built-in [ ] excluded <M> module < > module capable ───────────────────────────────────────────────────────────────────────────────────┐ │
│ │ <M> "limit" match support │ │
│ │ <M> "mac" address match support │ │
│ │ <M> "mark" match support │ │
│ │ < > IPsec "policy" match support │ │
│ │ <M> Multiple port match support │ │
│ │ <M> "pkttype" packet type match support │ │
│ │ < > "quota" match support │ │
│ │ <M> "realm" match support │ │
│ │ <M> "sctp" protocol match support (EXPERIMENTAL) │ │
│ │ <M> "state" match support
|
ciauz |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Thu Mar 08, 2007 10:57 am Post subject: |
|
|
Potresti postarmi tutta la tua configurazione della sezione netfilter? poi provvederò io a togliere tutto quello che sono sicuro non mi serve... _________________ LP |
|
Back to top |
|
|
crisandbea Veteran
Joined: 03 Jul 2005 Posts: 1778 Location: BOSCO (SA) ... ma domiciliato a Bologna....
|
Posted: Thu Mar 08, 2007 11:01 am Post subject: |
|
|
lucapost wrote: | Potresti postarmi tutta la tua configurazione della sezione netfilter? poi provvederò io a togliere tutto quello che sono sicuro non mi serve... |
Code: |
cat /usr/src/linux/.config | grep FILTER
CONFIG_NETFILTER=y
CONFIG_NETFILTER_DEBUG=y
# CONFIG_NETFILTER_NETLINK is not set
CONFIG_NETFILTER_XTABLES=m
CONFIG_NETFILTER_XT_TARGET_CLASSIFY=m
# CONFIG_NETFILTER_XT_TARGET_DSCP is not set
CONFIG_NETFILTER_XT_TARGET_MARK=m
CONFIG_NETFILTER_XT_TARGET_NFQUEUE=m
# CONFIG_NETFILTER_XT_TARGET_NOTRACK is not set
CONFIG_NETFILTER_XT_MATCH_COMMENT=m
CONFIG_NETFILTER_XT_MATCH_CONNTRACK=m
CONFIG_NETFILTER_XT_MATCH_DCCP=m
CONFIG_NETFILTER_XT_MATCH_DSCP=m
CONFIG_NETFILTER_XT_MATCH_ESP=m
CONFIG_NETFILTER_XT_MATCH_HELPER=m
CONFIG_NETFILTER_XT_MATCH_LENGTH=m
CONFIG_NETFILTER_XT_MATCH_LIMIT=m
CONFIG_NETFILTER_XT_MATCH_MAC=m
CONFIG_NETFILTER_XT_MATCH_MARK=m
# CONFIG_NETFILTER_XT_MATCH_POLICY is not set
CONFIG_NETFILTER_XT_MATCH_MULTIPORT=m
CONFIG_NETFILTER_XT_MATCH_PKTTYPE=m
# CONFIG_NETFILTER_XT_MATCH_QUOTA is not set
CONFIG_NETFILTER_XT_MATCH_REALM=m
CONFIG_NETFILTER_XT_MATCH_SCTP=m
CONFIG_NETFILTER_XT_MATCH_STATE=m
# CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set
# CONFIG_NETFILTER_XT_MATCH_STRING is not set
# CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set
CONFIG_IP_NF_FILTER=m
CONFIG_IP_NF_ARPFILTER=m
CONFIG_PPP_FILTER=y
|
spero possa esserti utile.
ciao |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Thu Mar 08, 2007 12:34 pm Post subject: |
|
|
Ho compilato TUTTA la sezione netfilter/iptables statica. Per ora è la soluzione più veloce ed efficace...
Non è ovviamente la soluzione ideale, quando avrò tempo magari mettero al suo posto quello che non serve.
ps: non è un consiglio a compilare tutte le opzioni del kernel come statiche quando non funziona qualcosa! _________________ LP |
|
Back to top |
|
|
djinnZ Advocate
Joined: 02 Nov 2006 Posts: 4831 Location: somewhere in L.O.S.
|
Posted: Thu Mar 08, 2007 1:06 pm Post subject: |
|
|
visto che sono pigro, non ho problemi di spazio e non ho mai voglia di andare a vedere cosa mi serve seguo un approccio leggermente differente, compilo tutto modulare e poi vado a vedere cosa è caricato per abilitarlo built-in, quello che non mi serve lo lascio modulare, non si sa mai.
Non ho resistito. _________________ scita et risus abundant in ore stultorum sed etiam semper severi insani sunt
mala tempora currunt...mater stultorum semper pregna est
Murpy'sLaw:If anything can go wrong, it will - O'Toole's Corollary:Murphy was an optimist |
|
Back to top |
|
|
|