ethanh Posted June 14, 2013 Share Posted June 14, 2013 I am using the following iptables script to redirect packets on port 443 to a proxy server: iptables -t mangle -A PREROUTING -p tcp --dport 443 -j MARK --set-mark 2 I am redirecting it to my proxy server later on, which is working. For one host, however, I need to remove the iptables mark (i.e. the packets will not be redirected.) I tried the following: iptables -t mangle -A PREROUTING -p tcp -s 192.168.0.47 --dport 443 -j ACCEPT I have also tried (attempting to rewrite the mark to a different number): iptables -t mangle -A PREROUTING -p tcp -s 192.168.0.47 --dport 443 -j MARK --set-mark 1 However none of them are working. Is there a --remove-mark? I couldn't find anything on Google.Any help would be appreciated. Quote Link to comment Share on other sites More sharing options...
Ice IT Support Posted June 15, 2013 Share Posted June 15, 2013 The -D or -X options might be what you are looking for. Quote Link to comment Share on other sites More sharing options...
ethanh Posted June 15, 2013 Author Share Posted June 15, 2013 Could you give an example? I am relatively new to iptables and am not quite sure what I am doing (just using it on a router to restrict access not going through our proxy). Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.