Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Networking & Security
  • Search

iptables and snat mac

Having problems getting connected to the internet or running a server? Wondering about securing your box? Ask here.
Post Reply
Advanced search
4 posts • Page 1 of 1
Author
Message
akam
Tux's lil' helper
Tux's lil' helper
Posts: 82
Joined: Mon Sep 04, 2006 8:05 am
Location: Nab. Chelny, Russia

iptables and snat mac

  • Quote

Post by akam » Fri Oct 14, 2011 2:20 pm

Hello, please tell me how to distribute the Internet for mac address. It does not work:
$IPTABLES -t nat -o $INET_IFACE -A POSTROUTING -m mac --mac-source 60:a1:0a:a7:fe:a7 -j SNAT --to-source $INET_IP
[17754.083715] x_tables: ip_tables: mac match: used from hooks POSTROUTING, but only valid from PREROUTING/INPUT/FORWARD
Top
truc
Advocate
Advocate
User avatar
Posts: 3199
Joined: Mon Jul 25, 2005 9:24 am

  • Quote

Post by truc » Fri Oct 14, 2011 6:23 pm

what exactly are you trying to do? (and why do you need that?) You usually don't need to do what you want to share an internet connection
The End of the Internet!
Top
akam
Tux's lil' helper
Tux's lil' helper
Posts: 82
Joined: Mon Sep 04, 2006 8:05 am
Location: Nab. Chelny, Russia

  • Quote

Post by akam » Fri Oct 14, 2011 8:29 pm

im trying to share internet to smartphones (over wifi). they are geting dynamic ip via dhcp (dont offer to reserve ip)

(sorry for my bad english)
Top
Hu
Administrator
Administrator
Posts: 24395
Joined: Tue Mar 06, 2007 5:38 am

  • Quote

Post by Hu » Sat Oct 15, 2011 2:14 am

If you only need to let the client devices connect outbound, then just use -j MASQUERADE instead of -j SNAT. You do not need to munge the MAC address.
Top
Post Reply

4 posts • Page 1 of 1

Return to “Networking & Security”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic