{"id":7778,"date":"2021-09-15T21:40:16","date_gmt":"2021-09-15T19:40:16","guid":{"rendered":"https:\/\/michlstechblog.info\/blog\/?p=7778"},"modified":"2021-09-16T17:50:40","modified_gmt":"2021-09-16T15:50:40","slug":"ftp-setup-a-simple-read-only-ftp-server-without-install-everything","status":"publish","type":"post","link":"https:\/\/michlstechblog.info\/blog\/ftp-setup-a-simple-read-only-ftp-server-without-install-everything\/","title":{"rendered":"FTP: Setup a simple (read only) FTP server without install everything"},"content":{"rendered":"<div class=\"twoclick_social_bookmarks_post_7778 social_share_privacy clearfix 1.6.4 locale-en_US sprite-en_US\"><\/div><div class=\"twoclick-js\"><script type=\"text\/javascript\">\/* <![CDATA[ *\/\njQuery(document).ready(function($){if($('.twoclick_social_bookmarks_post_7778')){$('.twoclick_social_bookmarks_post_7778').socialSharePrivacy({\"services\":{\"flattr\":{\"uid\":\"Michl\",\"status\":\"on\",\"the_title\":\"FTP%3A%20Setup%20a%20simple%20%28read%20only%29%20FTP%20server%20without%20install%20everything\",\"the_excerpt\":\"Hi%2C%0D%0A%0D%0Afor%20some%20reasons%2C%20for%20example%20firmware%20updatse%20of%20IoT%20devices%20you%20need%20a%20readonly%2Fanonymous%20FTP%20server%20and%20you%20don%27t%20wont%20install%20and%20configure%20a%20whole%20ftp%20solution%20for%20this.%0D%0A%0D%0AThe%20python%20module%20twisted%20offers%20such%20a%20simple%20server.%20The%20ftp%20server%20must%20started%20with%20root%20privileges%20because%20it%20uses%20a%20port%20%26lt%3B1024.%20I%20always%20create%20a%20virtual%20python%20environment%20%28ftp-venv%29%20for%20such%20things.%0D%0A%20...\",\"txt_info\":\"2 clicks for more data protection:\\r\\n\\r\\nOnly when you click here, the button will be come active and you can send your recommendation to Flattr. When activating, data are transmitted to third parties. \",\"perma_option\":\"off\"}},\"txt_help\":\"When you activate these fields by clicking, information to Flattr may be transferred abroad, and probably may also stored there.\",\"settings_perma\":\"Enable permanently and accept data transmission. \",\"info_link\":\"http:\\\/\\\/www.heise.de\\\/ct\\\/artikel\\\/2-Klicks-fuer-mehr-Datenschutz-1333879.html\",\"uri\":\"https:\\\/\\\/michlstechblog.info\\\/blog\\\/ftp-setup-a-simple-read-only-ftp-server-without-install-everything\\\/\",\"post_id\":7778,\"post_title_referrer_track\":\"FTP%3A+Setup+a+simple+%28read+only%29+FTP+server+without+install+everything\",\"display_infobox\":\"on\"});}});\n\/* ]]> *\/<\/script><\/div><p>Hi,<\/p>\n<p>for some reasons, for example firmware updatse of IoT devices you need a readonly\/anonymous FTP server and you don&#8217;t wont install and configure a whole ftp solution for this.<\/p>\n<p>The python module twisted offers such a simple server. The ftp server must started with root privileges because it uses a port <1024. I always create a virtual python environment (ftp-venv) for such things.\n<!--more--><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\nmichael@debdev ~ # sudo apt install python3 python3-pip python3-venv\r\nmichael@debdev ~ # python3 -m venv \/home\/michael\/ftp-venv\r\nmichael@debdev ~ # sudo su\r\nroot@debdev ~ # source \/home\/michael\/ftp-venv\/bin\/activate\r\nroot@debdev ~ # pip install twisted\r\nroot@debdev ~ # mkdir -p \r\nroot@debdev ~ # twistd -n ftp -p 21 -r \/tmp\/tftp\r\n<\/pre>\n<p>Copy the files you want to serve to \/tmp\/tftp<\/p>\n<p>Michael<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hi, for some reasons, for example firmware updatse of IoT devices you need a readonly\/anonymous FTP server and you don&#8217;t wont install and configure a whole ftp solution for this. The python module twisted offers such a simple server. The ftp server must started with root privileges because it uses a port &lt;1024. I always &hellip; <a href=\"https:\/\/michlstechblog.info\/blog\/ftp-setup-a-simple-read-only-ftp-server-without-install-everything\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">FTP: Setup a simple (read only) FTP server without install everything<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[629,224,1611,20,1612],"class_list":["post-7778","post","type-post","status-publish","format-standard","hentry","category-linux","tag-ftp","tag-linux-2","tag-simple","tag-windows-2","tag-without-install"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/posts\/7778","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/comments?post=7778"}],"version-history":[{"count":2,"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/posts\/7778\/revisions"}],"predecessor-version":[{"id":7780,"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/posts\/7778\/revisions\/7780"}],"wp:attachment":[{"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/media?parent=7778"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/categories?post=7778"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/michlstechblog.info\/blog\/wp-json\/wp\/v2\/tags?post=7778"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}