Skip to content

Instantly share code, notes, and snippets.

@leepa leepa/ftpserver.py
Created May 19, 2012

Embed
What would you like to do?
# pip install pyftpdlib then rock n roll
from pyftpdlib import ftpserver
authorizer = ftpserver.DummyAuthorizer()
authorizer.add_user("ftpshiz", "ftpshiz", "/usr/local/ftp", perm="elradfmw")
handler = ftpserver.FTPHandler
handler.authorizer = authorizer
address = ("127.0.0.1", 2121)
ftpd = ftpserver.FTPServer(address, handler)
ftpd.serve_forever()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.