sparty icon indicating copy to clipboard operation
sparty copied to clipboard

Illegal filename character while dumping frontpage service information

Open maaaaz opened this issue 11 years ago • 0 comments

Hello dude,

First, I would like to thank you for your NTLM patch, that was really a needed one.

Second, I would like to report a bug : you are not filtering illegal filename chars when you dump frontage service information.
In the frontpage_service_listing function, line 382:

filename = "__service-list__.txt" + entry + ".html"
service_list = open(filename, 'a')

entry comes from the list on line 370 and contains bad chars such as ':' (colon).

Please filter any bad char in filename before attempting to write into them with this:

re.sub('[^\w\-_\. ]', '_', filename)

Best regards, Thomas.

maaaaz avatar May 29 '14 11:05 maaaaz