{"id":497,"date":"2023-02-04T10:39:06","date_gmt":"2023-02-04T16:39:06","guid":{"rendered":"http:\/\/bogi.maramski.com\/?p=497"},"modified":"2023-02-04T10:43:01","modified_gmt":"2023-02-04T16:43:01","slug":"iptables-save-iptables-bak","status":"publish","type":"post","link":"https:\/\/bogi.maramski.com\/?p=497","title":{"rendered":"iptables-save > iptables.bak"},"content":{"rendered":"<p><strong>iptables-save > iptables.bak<\/strong><br \/>\n<strong>iptables-restore < iptables.bak<\/strong><\/p>\n<p><strong>bellow is my flush-iptables file<\/strong><\/p>\n<p><code>IPTABLES=\"\/sbin\/iptables\"<\/p>\n<p>#<br \/>\n# reset the default policies in the filter table.<br \/>\n#<br \/>\n$IPTABLES -P INPUT ACCEPT<br \/>\n$IPTABLES -P FORWARD ACCEPT<br \/>\n$IPTABLES -P OUTPUT ACCEPT<\/p>\n<p>#<br \/>\n# reset the default policies in the nat table.<br \/>\n#<br \/>\n$IPTABLES -t nat -P PREROUTING ACCEPT<br \/>\n$IPTABLES -t nat -P POSTROUTING ACCEPT<br \/>\n$IPTABLES -t nat -P OUTPUT ACCEPT<\/p>\n<p>#<br \/>\n# reset the default policies in the mangle table.<br \/>\n#<br \/>\n$IPTABLES -t mangle -P PREROUTING ACCEPT<br \/>\n$IPTABLES -t mangle -P OUTPUT ACCEPT<\/p>\n<p>#<br \/>\n# flush all the rules in the filter and nat tables.<br \/>\n#<br \/>\n$IPTABLES -F<br \/>\n$IPTABLES -t nat -F<br \/>\n$IPTABLES -t mangle -F<br \/>\n#<br \/>\n# erase all chains that's not default in filter and nat table.<br \/>\n#<br \/>\n$IPTABLES -X<br \/>\n$IPTABLES -t nat -X<br \/>\n$IPTABLES -t mangle -X<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>iptables-save > iptables.bak iptables-restore < iptables.bak bellow is my flush-iptables file IPTABLES=\"\/sbin\/iptables\" # # reset the default policies in the filter table. # $IPTABLES -P INPUT ACCEPT $IPTABLES -P FORWARD ACCEPT $IPTABLES -P OUTPUT ACCEPT # # reset the default policies in the nat table. # $IPTABLES -t nat -P PREROUTING ACCEPT $IPTABLES -t nat [&hellip;]\n<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-497","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=\/wp\/v2\/posts\/497"}],"collection":[{"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=497"}],"version-history":[{"count":6,"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=\/wp\/v2\/posts\/497\/revisions"}],"predecessor-version":[{"id":501,"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=\/wp\/v2\/posts\/497\/revisions\/501"}],"wp:attachment":[{"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=497"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=497"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bogi.maramski.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=497"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}