{"id":3020,"date":"2012-09-16T11:18:02","date_gmt":"2012-09-16T11:18:02","guid":{"rendered":"http:\/\/www.theperfectarts.com\/?p=3020"},"modified":"2014-11-21T06:55:57","modified_gmt":"2014-11-21T06:55:57","slug":"secure-wget-binary","status":"publish","type":"post","link":"https:\/\/www.ktchost.com\/blog\/secure-wget-binary\/","title":{"rendered":"Secure wget binary"},"content":{"rendered":"<p>The <strong>wget binary<\/strong> is used to hack the server therefore its always better to disable the wget binary server wide and enable it for specific users, if its required by the script hosted by specific users only else leave it disable.<\/p>\n<p>First check the wget binary path by using the command.<\/p>\n<p><strong>which wget<\/strong><\/p>\n<p>The above command will provide wget binary path.<\/p>\n<p><strong>\/usr\/bin\/wget<\/strong><\/p>\n<p>Now add the new group which is actually used to enable wget binary for specific users only.<\/p>\n<p><strong>groupadd wget<\/strong><\/p>\n<p>Now change the group for the wget binary.<\/p>\n<p><strong>chgrp wget \/usr\/bin\/wget<\/strong><\/p>\n<p>Disable the wget binary.<\/p>\n<p><strong>chmod 710 \/usr\/bin\/wget<\/strong><\/p>\n<p>To assign the wget binary to specific user refer to the following command.<\/p>\n<p><strong>usermod (options) username<\/strong><\/p>\n<p>For example, we want to enable the wget binary to the test123 user then run the following command.<\/p>\n<p><strong>usermod -G wget test123<\/strong><\/p>\n<p>Similarly you can disable the other binaries as well &#8230;<\/p>\n<p><!-- Place this tag where you want the +1 button to render --><br \/>\n<g:plusone><\/g:plusone><\/p>\n<p><!-- Place this render call where appropriate --><br \/>\n<script type=\"text\/javascript\">\n  (function() {\n    var po = document.createElement('script'); po.type = 'text\/javascript'; po.async = true;\n    po.src = 'https:\/\/apis.google.com\/js\/plusone.js';\n    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);\n  })();\n<\/script> <\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>The wget binary is used to hack the server therefore its always better to disable the wget binary server wide and enable it for specific <a class=\"mh-excerpt-more\" href=\"https:\/\/www.ktchost.com\/blog\/secure-wget-binary\/\" title=\"Secure wget binary\">[&#8230;]<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-3020","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/posts\/3020"}],"collection":[{"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/comments?post=3020"}],"version-history":[{"count":4,"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/posts\/3020\/revisions"}],"predecessor-version":[{"id":3770,"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/posts\/3020\/revisions\/3770"}],"wp:attachment":[{"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/media?parent=3020"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/categories?post=3020"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ktchost.com\/blog\/wp-json\/wp\/v2\/tags?post=3020"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}