Skip to content
This repository has been archived by the owner on Nov 24, 2021. It is now read-only.

Patch Creation Allows Windows Invalid Characters #3

Closed
le717 opened this issue Apr 17, 2013 · 3 comments
Closed

Patch Creation Allows Windows Invalid Characters #3

le717 opened this issue Apr 17, 2013 · 3 comments
Assignees
Labels
Milestone

Comments

@le717
Copy link
Owner

le717 commented Apr 17, 2013

Bug

By default, the Python input() box allows all characters to be entered, both strings, integers and floats. I do not think it has any internal character limits, not even on Windows. However, Windows has some internal character limits (see attached screenshot). Since Python does not seem to honor those limits, a very dangerous and serious bug is created, existent since V1.0 Beta 2, where a Patch could theoretically be created with an invalid character, and would be unable to delete it. I have had this happen to me once before. Ubuntu was duel-booted on a computer, and I took a screenshot. The screenshot had a colon in the file name, and colons are reserved for drive letters on Windows. Once I booted back into Windows, I was unable to edit, rename, move, copy, or delete the file, and Ubuntu had already been removed. It stayed there until the HDD was redone. This bug could create the situation, and that never needs to happen.

How to reproduce

Will not be written. As already stated, this is a dangerous bug to exploit, and will not tell how to do it and mess up someone's computer.

Fix

  • Attach a character checker to the Name and Version input fields during Patch Creation. I already have code to do this, and is easy to implement.

Screenshot

Windows Invalid Characters

@le717
Copy link
Owner Author

le717 commented Apr 20, 2013

This nasty bug has been fixed in commits dd6befd and cc46d22

It allows all characters except for the ones in the screenshot above.

@le717 le717 closed this as completed Apr 20, 2013
@ghost ghost assigned le717 May 2, 2013
@le717 le717 reopened this May 8, 2013
@le717
Copy link
Owner Author

le717 commented May 8, 2013

Bug

Just found a new bug related to this character check:

It does not allow spaces. So, if the mod is called

LEGO Racers Mod 1

you would have to enter it like this:

LEGORacersMod1

a that is clearly not the original name.

Fix

I may have created this error when I added the check. I'll go back and look at my prototype code, see if it allows spaces, and fix this bug afterward.

le717 pushed a commit that referenced this issue May 9, 2013
Successful Patch installation message is now displayed in green text,
Fixed character check not allowing spaces (see #3),
Incomplete Patch is now deleted if PermissionError is raised,
Adding correct version of Uninstaller,
More work on handlejam
@le717
Copy link
Owner Author

le717 commented May 9, 2013

New bug fixed in commit badfb67. It seems even my prototype code did not allow spaces. The fix? Just add a single space in the list of allowed characters, and Tada! Instant working code. :)

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

No branches or pull requests

1 participant