File tree 1 file changed +7
-2
lines changed
src/main/java/io/jenkins/update_center
1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -79,15 +79,20 @@ protected Set<ArtifactCoordinates> listAllJenkinsWars(String groupId) throws IOE
79
79
}
80
80
81
81
private static boolean containsIllegalChars (String test ) {
82
- return !test .chars ().allMatch (c -> c >= 0x2B && c < 0x7B );
82
+ return !test .chars ().allMatch (c ->
83
+ c >= '0' && c <= '9'
84
+ || c >= 'A' && c <= 'Z'
85
+ || c >= 'a' && c <= 'z'
86
+ || c == '+' || c == '-' || c == '.' || c == '/' || c == '_'
87
+ );
83
88
}
84
89
85
90
private static ArtifactCoordinates toGav (JsonFile f ) {
86
91
String fileName = f .name ;
87
92
String path = f .path ;
88
93
89
94
if (containsIllegalChars (fileName ) || containsIllegalChars (path )) {
90
- LOGGER .log (Level .INFO , "Not only printable ascii : " + f .path + " / " + f .name );
95
+ LOGGER .log (Level .INFO , "Characters outside allowed set : " + f .path + " / " + f .name );
91
96
return null ;
92
97
}
93
98
You can’t perform that action at this time.
0 commit comments