Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot retrieve a file in a subdirectory #13

Open
GoogleCodeExporter opened this issue Oct 7, 2015 · 0 comments
Open

cannot retrieve a file in a subdirectory #13

GoogleCodeExporter opened this issue Oct 7, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. mkdir -p A
2. touch A/B
3. start tftp server pointing at directory with A as root dir
4. request file /A/B

What is the expected output? What do you see instead?

I expect to see file B returned. Instead my TFTP client times out. No TFTP 
error codes are returned.


What version of the product are you using? On what operating system?

v3.1 on Linux (Ubuntu 13.04 \n \l)


Please provide any additional information below.

The problem is located in tftp_engine.py at lines 621-628 where the filename is 
checked for valid characters. Unfortunately, '/' is not considered a valid 
character and this is why the filename is silently rejected.

Add this before the test to _escape_ the '/' character.

        temp_filename=temp_filename.replace("/", "x")


Original issue reported on code.google.com by [email protected] on 17 Sep 2013 at 12:15

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant