Stranica: 1/1.

suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 19:34
Postao/la balonja
Pozdrav
nov sam u ovim sistemima iako nesto malo i poznajem...uglavnom:

desk pc je suse 11.1
lap je XP sp2
spojio sam im crossover kabelom

mogu jedan drugog pingati ( ukoliko pogasim firewall na SUSE-u)
napravio i masquerade al nikako postici da preko SUSE iziđšem na net..
gledam i kopam svašta
cak sam tri puta napravio reinstal suse i xp-a...

evo logovi:

Kod: Označi sve

iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere state ESTABLISHED
ACCEPT icmp -- anywhere anywhere state RELATED
input_ext all -- anywhere anywhere
input_dmz all -- anywhere anywhere
input_ext all -- anywhere anywhere
LOG all -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-IN-ILL-TARGET '
DROP all -- anywhere anywhere

Chain FORWARD (policy DROP)
target prot opt source destination
TCPMSS tcp -- anywhere anywhere tcp flags:SYN,RST/SYN TCPMSS clamp to PMTU
forward_ext all -- anywhere anywhere
forward_dmz all -- anywhere anywhere
LOG all -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-FWD-ILL-ROUTING '
DROP all -- anywhere anywhere

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere state NEW,RELATED,ESTABLISHED
LOG all -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-OUT-ERROR '

Chain forward_dmz (1 references)
target prot opt source destination
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp echo-reply
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp destination-unreachable
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp time-exceeded
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp parameter-problem
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp timestamp-reply
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp address-mask-reply
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp protocol-unreachable
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp redirect
ACCEPT all -- anywhere anywhere state NEW,RELATED,ESTABLISHED
LOG all -- anywhere anywhere limit: avg 3/min burst 5 PKTTYPE = multicast LOG level warning tcp-options ip-options prefix `SFW2-FWDdmz-DROP-DEFLT '
DROP all -- anywhere anywhere PKTTYPE = multicast
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-FWDdmz-DROP-DEFLT '
LOG icmp -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-FWDdmz-DROP-DEFLT '
LOG udp -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-FWDdmz-DROP-DEFLT '
LOG all -- anywhere anywhere limit: avg 3/min burst 5 state INVALID LOG level warning tcp-options ip-options prefix `SFW2-FWDdmz-DROP-DEFLT-INV '
DROP all -- anywhere anywhere

Chain forward_ext (1 references)
target prot opt source destination
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp echo-reply
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp destination-unreachable
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp time-exceeded
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp parameter-problem
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp timestamp-reply
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp address-mask-reply
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp protocol-unreachable
ACCEPT icmp -- anywhere anywhere state RELATED,ESTABLISHED icmp redirect
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
LOG all -- anywhere anywhere limit: avg 3/min burst 5 PKTTYPE = multicast LOG level warning tcp-options ip-options prefix `SFW2-FWDext-DROP-DEFLT '
DROP all -- anywhere anywhere PKTTYPE = multicast
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-FWDext-DROP-DEFLT '
LOG icmp -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-FWDext-DROP-DEFLT '
LOG udp -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-FWDext-DROP-DEFLT '
LOG all -- anywhere anywhere limit: avg 3/min burst 5 state INVALID LOG level warning tcp-options ip-options prefix `SFW2-FWDext-DROP-DEFLT-INV '
DROP all -- anywhere anywhere

Chain input_dmz (1 references)
target prot opt source destination
DROP all -- anywhere anywhere PKTTYPE = broadcast
ACCEPT icmp -- anywhere anywhere icmp source-quench
ACCEPT icmp -- anywhere anywhere icmp echo-request
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:netbios-ssn flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INdmz-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:netbios-ssn
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:microsoft-ds flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INdmz-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:microsoft-ds
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp spt:microsoft-ds dpts:1024:65535 flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INdmz-ACC-HIGH '
ACCEPT tcp -- anywhere anywhere tcp spt:microsoft-ds dpts:1024:65535
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp spt:netbios-ns dpts:1024:65535 flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INdmz-ACC-HIGH '
ACCEPT tcp -- anywhere anywhere tcp spt:netbios-ns dpts:1024:65535
LOG udp -- anywhere anywhere limit: avg 3/min burst 5 state NEW udp spt:microsoft-ds dpts:1024:65535 LOG level warning tcp-options ip-options prefix `SFW2-INdmz-ACC-HiUDP '
ACCEPT udp -- anywhere anywhere state NEW udp spt:microsoft-ds dpts:1024:65535
LOG udp -- anywhere anywhere limit: avg 3/min burst 5 state NEW udp spt:netbios-ns dpts:1024:65535 LOG level warning tcp-options ip-options prefix `SFW2-INdmz-ACC-HiUDP '
ACCEPT udp -- anywhere anywhere state NEW udp spt:netbios-ns dpts:1024:65535
LOG all -- anywhere anywhere limit: avg 3/min burst 5 PKTTYPE = multicast LOG level warning tcp-options ip-options prefix `SFW2-INdmz-DROP-DEFLT '
DROP all -- anywhere anywhere PKTTYPE = multicast
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INdmz-DROP-DEFLT '
LOG icmp -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-INdmz-DROP-DEFLT '
LOG udp -- anywhere anywhere limit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-INdmz-DROP-DEFLT '
LOG all -- anywhere anywhere limit: avg 3/min burst 5 state INVALID LOG level warning tcp-options ip-options prefix `SFW2-INdmz-DROP-DEFLT-INV '
DROP all -- anywhere anywhere

Chain input_ext (2 references)
target prot opt source destination
ACCEPT udp -- anywhere anywhere PKTTYPE = broadcast udp dpt:netbios-ns
ACCEPT udp -- anywhere anywhere PKTTYPE = broadcast udp dpt:netbios-dgm
ACCEPT udp -- anywhere anywhere PKTTYPE = broadcast udp dpt:bootps
ACCEPT udp -- anywhere anywhere PKTTYPE = broadcast udp dpt:netbios-ns
ACCEPT udp -- anywhere anywhere PKTTYPE = broadcast udp dpt:netbios-dgm
DROP all -- anywhere anywhere PKTTYPE = broadcast
ACCEPT icmp -- anywhere anywhere icmp source-quench
ACCEPT icmp -- anywhere anywhere icmp echo-request
ACCEPT udp -- 192.168.0.0/16 anywhere udp spt:netbios-ns state RELATED
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:microsoft-ds flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:microsoft-ds
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:netbios-dgm flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:netbios-dgm
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:netbios-ns flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:netbios-ns
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:netbios-ssn flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:netbios-ssn
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:netbios-ssn flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:netbios-ssn
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp dpt:microsoft-ds flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-TCP '
ACCEPT tcp -- anywhere anywhere tcp dpt:microsoft-ds
ACCEPT udp -- anywhere anywhere udp dpt:netbios-ns
ACCEPT udp -- anywhere anywhere udp dpt:bootps
ACCEPT udp -- anywhere anywhere udp dpt:netbios-ns
ACCEPT udp -- anywhere anywhere udp dpt:netbios-dgm
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp spt:microsoft-ds dpts:1024:65535 flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-HIGH '
ACCEPT tcp -- anywhere anywhere tcp spt:microsoft-ds dpts:1024:65535
LOG tcp -- anywhere anywhere limit: avg 3/min burst 5 tcp spt:netbios-ns dpts:1024:65535 flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-HIGH '
ACCEPT tcp -- anywhere anywheretcp spt:netbios-ns dpts:1024:65535
LOG udp -- anywhere anywherelimit: avg 3/min burst 5 state NEW udp spt:microsoft-ds dpts:1024:65535 LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-HiUDP '
ACCEPT udp -- anywhere anywherestate NEW udp spt:microsoft-ds dpts:1024:65535
LOG udp -- anywhere anywherelimit: avg 3/min burst 5 state NEW udp spt:netbios-ns dpts:1024:65535 LOG level warning tcp-options ip-options prefix `SFW2-INext-ACC-HiUDP '
ACCEPT udp -- anywhere anywherestate NEW udp spt:netbios-ns dpts:1024:65535
LOG all -- anywhere anywherelimit: avg 3/min burst 5 PKTTYPE = multicast LOG level warning tcp-options ip-options prefix `SFW2-INext-DROP-DEFLT '
DROP all -- anywhere anywherePKTTYPE = multicast
LOG tcp -- anywhere anywherelimit: avg 3/min burst 5 tcp flags:FIN,SYN,RST,ACK/SYN LOG level warning tcp-options ip-options prefix `SFW2-INext-DROP-DEFLT '
LOG icmp -- anywhere anywherelimit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-INext-DROP-DEFLT '
LOG udp -- anywhere anywherelimit: avg 3/min burst 5 LOG level warning tcp-options ip-options prefix `SFW2-INext-DROP-DEFLT '
LOG all -- anywhere anywherelimit: avg 3/min burst 5 state INVALID LOG level warning tcp-options ip-options prefix `SFW2-INext-DROP-DEFLT-INV '
DROP all -- anywhere anywhere

Chain reject_func (0 references)
target prot opt source destination
REJECT tcp -- anywhere anywherereject-with tcp-reset
REJECT udp -- anywhere anywherereject-with icmp-port-unreachable
REJECT all -- anywhere anywherereject-with icmp-proto-unreachable
_______________________________________________________

 # route -n
Kernel IP routing table
Destination Gateway Genmask Flags MetricRef Use Iface
195.29.96.241 0.0.0.0 255.255.255.255 UH 00 0 modem0
1.1.1.0 0.0.0.0 255.255.255.0 U 00 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 00 0 eth0
192.168.0.0 0.0.0.0 255.255.0.0 U 00 0 eth0
127.0.0.0 0.0.0.0 255.0.0.0 U 00 0 lo
0.0.0.0 0.0.0.0 0.0.0.0 U 00 0 modem0

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 19:51
Postao/la glaskoncILLa
odgovorio sam ti vec na linux.hr, dakle ajde za pocetak ugasi taj firewall i nemoj ga uopce paliti dok ne budes razumio sto pise u njemu jer to nema previse smisla, pogotovo zato jer po defaultu se uopce ne mozes remotely spojiti na linux kantu, a windows kanta nece biti dostupna direktno sa neta.

nakon toga enableaj ip forwarding i napravi masquerading po onom linku koji sam ti dao.

kad to napravis stavi na forum ispis komadi iz terminala;

Kod: Označi sve

ifconfig
route -n
iptables -L
cat /etc/resolv.conf
cat /proc/sys/net/ipv4/ip_forward
i napisi sto si stavio na windowse kao ip adresu, netmask, default gateway i dns-ove.

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 20:07
Postao/la balonja

Kod: Označi sve

kw:/home/kw # ifconfig                                                       
eth0      Link encap:Ethernet  HWaddr 00:48:54:6D:1A:96                      
          inet addr:192.168.2.2  Bcast:192.168.255.255  Mask:255.255.0.0     
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1                 
          RX packets:414 errors:0 dropped:0 overruns:0 frame:0               
          TX packets:446 errors:0 dropped:0 overruns:0 carrier:0             
          collisions:0 txqueuelen:1000                                       
          RX bytes:43956 (42.9 Kb)  TX bytes:57133 (55.7 Kb)                 
          Interrupt:9 Base address:0x4000                                    

eth0:kw12 Link encap:Ethernet  HWaddr 00:48:54:6D:1A:96  
          inet addr:1.1.1.4  Bcast:1.1.1.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1    
          Interrupt:9 Base address:0x4000                       

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:19742 errors:0 dropped:0 overruns:0 frame:0
          TX packets:19742 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0                               
          RX bytes:582090 (568.4 Kb)  TX bytes:582090 (568.4 Kb)  

modem0    Link encap:Point-to-Point Protocol  
          inet addr:195.29.100.108  P-t-P:195.29.100.241  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1          
          RX packets:618 errors:0 dropped:0 overruns:0 frame:0                
          TX packets:658 errors:0 dropped:0 overruns:0 carrier:0              
          collisions:0 txqueuelen:3
          RX bytes:347047 (338.9 Kb)  TX bytes:100279 (97.9 Kb)

kw:/home/kw # cat /etc/resolv.conf
### /etc/resolv.conf file autogenerated by netconfig!
#
# Before you change this file manually, consider to define the
# static DNS configuration using the following variables in the
# /etc/sysconfig/network/config file:
#     NETCONFIG_DNS_STATIC_SEARCHLIST
#     NETCONFIG_DNS_STATIC_SERVERS
#     NETCONFIG_DNS_FORWARDER
# or disable DNS configuration updates via netconfig by setting:
#     NETCONFIG_DNS_POLICY=''
#
# See also the netconfig(8) manual page and other documentation.
#
# Note: Manual change of this file disables netconfig too, but
# may get lost when this file contains comments or empty lines
# only, the netconfig settings are same with settings in this
# file and in case of a "netconfig update -f" call.
#
### Please remove (at least) this line when you modify the file!
search WORKGROUP
nameserver 195.29.166.117
nameserver 195.29.149.197
kw:/home/kw # cat /proc/sys/net/ipv4/ip_forward
1
kw:/home/kw # iptables -L
Chain INPUT (policy DROP)
target     prot opt source               destination
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED
ACCEPT     all  --  anywhere             anywhere            state NEW
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:http
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:https
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:domain

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination

win
ip 192.168.2.10
netmask 255.255.0.0
gateway 192.168.2.2
dns 192.168.2.2

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 20:16
Postao/la glaskoncILLa
jos uvijek nemas nat;

Kod: Označi sve

iptables -t nat -A POSTROUTING -o modem0 -j MASQUERADE
i na windowse stavi ove dns-ove;

Kod: Označi sve

195.29.166.117
195.29.149.197

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 20:23
Postao/la balonja
ubbeeeeerrrrr cooolll
radi :D
puno puno hvala

samo
imam jedno pitanje

zasto ovi dns-ovi?

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 20:41
Postao/la glaskoncILLa
zato sto tvoj linux nije dns server, ako napravis nmap -sU 192.168.2.2 vidjeti ces da ne slusa na udp 53, odnosno adresa dns treba biti adresa necega sto je pravi dns ili barem nesto slicno..

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 20:45
Postao/la balonja
aha(morao sam malo kopati da skuzim sto pricas)
hvala ljepa jos jednom :)

Re: suse 11.1 xpsp2 crossover

Postano: 28 lis 2009, 20:56
Postao/la glaskoncILLa
e da, iptablesi ti nece prezivjeti reboot, dakle napravi;

Kod: Označi sve

iptables-save > /etc/iptables.cfg
to ce spremiti trenutnu konfiguraciju iptablesa u file iptables u direktoriju etc.
file ce se sam kreirati kod izvrsenja komande, dakle ne moras brinuti o tome.
ono o cemu moras brinuti je kako vratiti tu konfiguraciju kod svakog boota, trebao bi staviti;

Kod: Označi sve

iptables-restore < /etc/iptables.cfg
u neku skriptu koja ce se izvrsiti kod svakog bootanja, dakle ekvivalent onoga sto je na vecini drugih distri file/skripta rc.local ili u neki interface up/down file..
e to na suseu ne postoji, odnosno rc.local ne postoji
pa ili googlaj ili cekaj nekoga tko se druzio sa susesisom da ti kaze nesto konkretnije jer ja nemam pojma.