[MDSAL-185] Java binding v1: Invalid file/directory names for Windows in JAR Created: 07/Jul/16 Updated: 09/Mar/18 Resolved: 10/Mar/17 |
|
| Status: | Resolved |
| Project: | mdsal |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Vratko Polak | Assignee: | Unassigned |
| Resolution: | Won't Do | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| Issue Links: |
|
||||||||||||
| External issue ID: | 6172 | ||||||||||||
| Description |
|
Some innocuous identifiers can lead to maven-bundle-plugin refusing to create the final jar file. For example: container con { Leads to: [ERROR] Bundle <...> : Invalid file/directory names for Windows in JAR: [<...>]. You can set the regular expression used with -invalidfilenames, the default expression is CON(\..)?|PRN(\..)?|AUX(\..)?|CLOCK\$|NUL(\..)?|COM[1-9](\..)?|LPT[1-9](\..)?|\$Mft|\$MftMirr|\$LogFile|\$Volume|\$AttrDef|\$Bitmap|\$Boot|\$BadClus|\$Secure|\$Upcase|\$Extend|\$Quota|\$ObjId|\$Reparse It should be possible to use a less restrictive pattern (after verifying it on Windows). |
| Comments |
| Comment by Vratko Polak [ 07/Jul/16 ] |
|
Complete example module: https://git.opendaylight.org/gerrit/41483 |
| Comment by Vratko Polak [ 07/Jul/16 ] |
|
A less obvious example: https://git.opendaylight.org/gerrit/41485 container in-con-troll { } Foo gets compiled into (...)/in/con/troll/Foo.class which contains the prohibited "con". |
| Comment by Martin Ciglan [ 07/Jul/16 ] |
|
looks like OSGi limitation: |
| Comment by Robert Varga [ 17/Oct/16 ] |
|
Actually, this is a Windows limitation, where it resolves some names to devices – irrespective in which context that name is used. |
| Comment by Martin Ciglan [ 21/Feb/17 ] |
|
https://ionicflux.wordpress.com/2006/09/02/windows-reserved-words/ |
| Comment by Jakub Toth [ 21/Feb/17 ] |
|
CON, PRN, AUX, CLOCK$, NUL, COM0, COM1, COM2, COM3, COM4, COM5, COM6, COM7, COM8, COM9, LPT0, LPT1, LPT2, LPT3, LPT4, LPT5, LPT6, LPT7, LPT8, LPT9 |
| Comment by Martin Ciglan [ 21/Feb/17 ] |
|
this is a simple addition to existing patch in Binding spec v2 so let's fix it in new bug and leave this one connected to v1 as it was |