{"id":1327,"date":"2020-06-10T21:00:00","date_gmt":"2020-06-10T19:00:00","guid":{"rendered":"https:\/\/blog.mhasin.eu\/?p=1327"},"modified":"2020-06-10T21:00:01","modified_gmt":"2020-06-10T19:00:01","slug":"linux-iptables-nat","status":"publish","type":"post","link":"https:\/\/blog.mhasin.eu\/?p=1327","title":{"rendered":"Linux iptables NAT"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Nastavenie NAT:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>iptables -t nat -A POSTROUTING -d 192.168.204.0\/23 -o eth0 -j MASQUERADE<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>-d 192.168.204.0\/23  - IP rozsah ktory chceme aby sa natoval. Teda ak klient zada poziadavku na tento IP rozsah tak dojde k NAT na ine zariadenie\n\n-o eth0 - interface kktorym ma trafik vystupovat vonku\n\n<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"488\" src=\"https:\/\/blog.mhasin.eu\/wp-content\/uploads\/2020\/06\/obr\u00e1zok-4-1024x488.png\" alt=\"\" class=\"wp-image-1328\" srcset=\"https:\/\/blog.mhasin.eu\/wp-content\/uploads\/2020\/06\/obr\u00e1zok-4-1024x488.png 1024w, https:\/\/blog.mhasin.eu\/wp-content\/uploads\/2020\/06\/obr\u00e1zok-4-300x143.png 300w, https:\/\/blog.mhasin.eu\/wp-content\/uploads\/2020\/06\/obr\u00e1zok-4-768x366.png 768w, https:\/\/blog.mhasin.eu\/wp-content\/uploads\/2020\/06\/obr\u00e1zok-4.png 1272w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n<div class=\"pdf24Plugin-cp\"> \t<form name=\"pdf24Form0\" method=\"post\" action=\"https:\/\/doc2pdf.pdf24.org\/wordpress.php\" target=\"pdf24PopWin\" onsubmit=\"var pdf24Win = window.open('about:blank', 'pdf24PopWin', 'resizable=yes,scrollbars=yes,width=600,height=250,left='+(screen.width\/2-300)+',top='+(screen.height\/3-125)+''); pdf24Win.focus(); if(typeof pdf24OnCreatePDF === 'function'){void(pdf24OnCreatePDF(this,pdf24Win));}\"> \t\t<input type=\"hidden\" name=\"blogCharset\" value=\"Cw1x07UAAA==\" \/><input type=\"hidden\" name=\"blogPosts\" value=\"MwQA\" \/><input type=\"hidden\" name=\"blogUrl\" value=\"yygpKSi20tdPyslP18vNSCzOzNNLLQUA\" \/><input type=\"hidden\" name=\"blogName\" value=\"c\/LxdwcA\" \/><input type=\"hidden\" name=\"blogValueEncoding\" value=\"gzdeflate base64\" \/><input type=\"hidden\" name=\"postId_0\" value=\"MzQ2MgcA\" \/><input type=\"hidden\" name=\"postTitle_0\" value=\"88nMK61QyCwoSUzKSS1W8HMMAQA=\" \/><input type=\"hidden\" name=\"postLink_0\" value=\"yygpKSi20tdPyslP18vNSCzOzNNLLdW3L7A1NDYyBwA=\" \/><input type=\"hidden\" name=\"postAuthor_0\" value=\"y00syfcwNAIA\" \/><input type=\"hidden\" name=\"postDateTime_0\" value=\"MzIwMtA1MNM1NFAwMrQyMLMyMAAA\" \/><input type=\"hidden\" name=\"postContent_0\" value=\"rZJNbtswEIX3OsWAqxYIRVkyHNewDRhoUGRRJ02cA4wlWmL0Q4KkZFu36Vl6sYxkoAiQLAq42pBDzXxv5pHB0kBaoXMrdjR8X+m05AYt5hZNwdZbdB472SgJ281usRRmHdC3NFZ+KEt1Jtl6OSxrZTzuK+mAe2jQA9\/A48Pz7unhZXe\/\/QE8g8m3OJzM5mEcTcNIxAlwDdIXEfBX+Ll5\/vVy97T5frcUI450rfw35c\/QwOH+EazuHRZQem3PkBaprCXg\/gwOhxZ1h1UIO5khYAllpWTjoUcKje4VrV3ZUh54OtfvcJ6yM\/2aSSgHi4YU1UiqtFQ0GBcEfyejP17aA6aUPLZRQ01EiwdVQnd2vjXUhodON2VLs34Y\/qDy9pP5VY25BKd6ySu0+eCFqnOoNGaqyVeswv7MIJOEG2N05yZlcFSZL1ZsEsVTBoVUeeFXbDqfM3A2XbHCe+MWQpBGHtYFOtWEshWkmupmsEG0ZpBwIo7iSEQzoff2z+9el3zKB+iJWKFpcgZYEZm963vsmE+S+CLmpP+PejAExxu4CphE0WkyTUYe7a\/F3c7mp2Q2G3G0vxJ3mTK+jY9svHYyFVuvb+BLjSc+3utidMGcvtIadaR3CRkIelCXd7QO3gA=\" \/> \t\t<a href=\"https:\/\/www.pdf24.org\" target=\"_blank\" title=\"www.pdf24.org\" rel=\"nofollow\"><img src=\"https:\/\/blog.mhasin.eu\/wp-content\/plugins\/pdf24-post-to-pdf\/img\/pdf_32x32.png\" alt=\"\" border=\"0\" height=\"32\" \/><\/a> \t\t<span class=\"pdf24Plugin-cp-space\">\u00a0\u00a0<\/span> \t\t<span class=\"pdf24Plugin-cp-text\">Send article as PDF<\/span> \t\t<span class=\"pdf24Plugin-cp-space\">\u00a0\u00a0<\/span> \t\t<input class=\"pdf24Plugin-cp-input\" style=\"margin: 0px;\" type=\"text\" name=\"sendEmailTo\" placeholder=\"Enter email address\" \/> \t\t<input class=\"pdf24Plugin-cp-submit\" style=\"margin: 0px;\" type=\"submit\" value=\"Send\" \/> \t<\/form> <\/div>","protected":false},"excerpt":{"rendered":"Nastavenie NAT: \u00a0\u00a0 Send article as PDF \u00a0\u00a0\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"arc_restricted_post":false,"footnotes":""},"categories":[4],"tags":[],"class_list":["post-1327","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=\/wp\/v2\/posts\/1327","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1327"}],"version-history":[{"count":1,"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=\/wp\/v2\/posts\/1327\/revisions"}],"predecessor-version":[{"id":1329,"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=\/wp\/v2\/posts\/1327\/revisions\/1329"}],"wp:attachment":[{"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1327"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1327"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.mhasin.eu\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1327"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}