msoulier/tftpy — pull request #38 by UnwashedMeme (2013-11-01 15:26:49+00:00)
Title: Fixing #11: server accept leading '/' in uploads

Some devices, when uploading, always have a leading '/' that led to the
joined path being outside the server's root directory causing "bad file
path" TftpExceptions. The only way to work around this is if the remote
client knew the full path on this server (unnecessarily tight coupling).

This patch removes the leading '/' so that all paths are relative to the
server's root directory.

To help preserve backwards compatibility there is an exception to the
above rule that if the client's specified path starts with the server's
root directory then accept it.