Jump to content

Internet Connection sharing with dhcp


Guest user101
 Share

Recommended Posts

Guest user101

Hello,

I followed this how to to setup internet connection sharing between linux and windows, linux being the computer connected to the internet, but I couldn't get it to work.

Windows to windows sharing, however, works fine and so does windows to linux.

 

I have a cable modem so I used dhcp and am using mandrake 10.1.b2.

The ipaddress of the ethernet card that connects one machine to to other is 192.168.0.1

Below I will copy and paste my config files.

Below is the config file for the card that is connected to the internet.

-------------------------/etc/sysconfig/network-scripts/ifcfg-eth0------------------------------------

 

DEVICE=eth0

BOOTPROTO=dhcp

ONBOOT=yes

MII_NOT_SUPPORTED=no

NEEDHOSTNAME=yes

-----------------------------------------------------------

card used for sharing connection

---------------------/etc/sysconfig/network-scripts/ifcfg-eth1--------------------------------------

etc/syDEVICE=eth1

BOOTPROTO=static

IPADDR=192.168.0.1

NETMASK=255.255.255.0

NETWORK=192.168.0.0

BROADCAST=192.168.0.255

ONBOOT=yes

MII_NOT_SUPPORTED=yes

-----------------------------------------------------------

 

I don't have a resolve.conf

 

-------------/etc/sysconfig/network:-----------

 

NETWORKING=yes

FORWARD_IPV4=true

GATEWAY=192.168.0.1

-----------------------------------

Posting the first couple of lines from /etc/sysctl.conf.

I didn't need to add net.ipv4.ip_forward = 1 as it was already added, I just changed it from 0 to 1.

----------/etc/sysctl.conf-----------------

 

# Controls IP packet forwarding

net.ipv4.ip_forward = 1

# Disables IP dynaddr

net.ipv4.ip_dynaddr = 0

# Disable ECN

net.ipv4.tcp_ecn = 0

# Controls source route verification

net.ipv4.conf.default.rp_filter = 1

--------------------------------

 

And in /etc/rc.d/rc.local I added iptables -t nat -D PREROUTING -i eth0 -j loc_dnat.

 

So that is what I am done so far and I can't get internet connection sharing to work.

Any suggestions would be appreciated.

thanks,

--user101

Link to comment
Share on other sites

Guest user101

Hey,

After doing what you said I did a security can at scan.sygate.com and according to it all of my ports are closed, not blocked anymore, except dns and icmp.

Anyway to get everything to be blocked without breaking interent sharing?

Even the windows firewall blocks everything.

 

--user101

Link to comment
Share on other sites

Guest user101

Ideally your port should be "Blocked." This indicates that your ports are not only closed, but they are completely hidden (stealthed) to the world.

Closed means that they are not hidden and can be scanned to figure out which type of attack to carry out.

and open....

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...