-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bumping up the version of spotless apply
- Loading branch information
Karan Preet Singh Sasan
authored and
Karan Preet Singh Sasan
committed
Jul 29, 2024
1 parent
8604465
commit ec92210
Showing
32 changed files
with
71 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"type": "java", | ||
"name": "Debug (Attach)", | ||
"projectName": "MyApplication", | ||
"request": "attach", | ||
"hostName": "localhost", | ||
"port": 5005 | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/ExtensionFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/AttackVector.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/FileUploadAttackExecutor.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/antivirus/EicarAntivirusTestFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/apache/htaccess/HTAccessFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/model/FileExtensionOperation.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/model/FileInformationProviderBuilder.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -17,7 +17,9 @@ | |
import java.util.Random; | ||
import org.sasanlabs.fileupload.exception.FileUploadException; | ||
|
||
/** @author KSASAN [email protected] */ | ||
/** | ||
* @author KSASAN [email protected] | ||
*/ | ||
class FileInformationProviderImpl implements FileInformationProvider { | ||
|
||
private String baseFileName; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -15,7 +15,9 @@ | |
|
||
import java.util.function.Function; | ||
|
||
/** @author KSASAN [email protected] */ | ||
/** | ||
* @author KSASAN [email protected] | ||
*/ | ||
public class SimpleFileInformationProvider implements FileInformationProvider { | ||
|
||
private Function<String, String> fileNameFunction; | ||
|
@@ -36,5 +38,6 @@ public String getFileName(String originalFileName) { | |
@Override | ||
public String getContentType(String originalContentType) { | ||
return this.contentTypeFunction.apply(originalContentType); | ||
}; | ||
} | ||
; | ||
} |
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/model/VulnerabilityType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -30,7 +30,9 @@ | |
import org.sasanlabs.fileupload.exception.FileUploadException; | ||
import org.sasanlabs.fileupload.matcher.impl.ContainsExpectedValueMatcher; | ||
|
||
/** @author [email protected] KSASAN */ | ||
/** | ||
* @author [email protected] KSASAN | ||
*/ | ||
public class ImageWithJSPSnippetFileUpload extends AttackVector { | ||
|
||
private static final String GIF_IMAGE_JSP_INJECTED_IN_EXIF_BASE64_ENCODED = | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -24,7 +24,9 @@ | |
import org.sasanlabs.fileupload.matcher.ContentMatcher; | ||
import org.sasanlabs.fileupload.matcher.impl.MD5HashResponseMatcher; | ||
|
||
/** @author KSASAN [email protected] */ | ||
/** | ||
* @author KSASAN [email protected] | ||
*/ | ||
public class SimpleJSPFileUpload extends AttackVector { | ||
|
||
private static final String JSP_UPLOADED_FILE_BASE_NAME = "SimpleJSPFileUpload_"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -27,7 +27,9 @@ | |
import org.sasanlabs.fileupload.matcher.ContentMatcher; | ||
import org.sasanlabs.fileupload.matcher.impl.MD5HashResponseMatcher; | ||
|
||
/** @author KSASAN [email protected] */ | ||
/** | ||
* @author KSASAN [email protected] | ||
*/ | ||
public class SimpleJSPXFileUpload extends AttackVector { | ||
|
||
private static final String JSPX_UPLOADED_FILE_BASE_NAME = "SimpleJSPXFileUpload_"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -30,7 +30,9 @@ | |
import org.sasanlabs.fileupload.exception.FileUploadException; | ||
import org.sasanlabs.fileupload.matcher.impl.ContainsExpectedValueMatcher; | ||
|
||
/** @author KSASAN [email protected] */ | ||
/** | ||
* @author KSASAN [email protected] | ||
*/ | ||
public class ImageWithPHPSnippetFileUpload extends AttackVector { | ||
private static final String GIF_IMAGE_PHP_INJECTED_IN_EXIF_BASE64_ENCODED = | ||
"R0lGODlhAQABAIAAAP///wAAACH5BAAAAAAAIf5JPD9waHAgZWNobyAiSW1hZ2VXaXRoUEhQU25pcHBldEZpbGVVcGxvYWRfIi4iU2FzYW5MYWJzX1pBUF9JZGVudGlmaWVyIiA/PgAsAAAAAAEAAQAAAgJEAQA7"; | ||
|
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/rce/php/SimplePHPFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/xss/HtmlFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/attacks/xss/SVGFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/exception/FileUploadException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/** | ||
* Copyright 2021 SasanLabs | ||
* Copyright 2024 SasanLabs | ||
* | ||
* <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file | ||
* except in compliance with the License. You may obtain a copy of the License at | ||
|
@@ -13,7 +13,9 @@ | |
*/ | ||
package org.sasanlabs.fileupload.function; | ||
|
||
/** @author [email protected] KSASAN */ | ||
/** | ||
* @author [email protected] KSASAN | ||
*/ | ||
@FunctionalInterface | ||
public interface ConsumerWithException<T, E extends Exception> { | ||
void accept(T val) throws E; | ||
|
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/i18n/FileUploadI18n.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/locator/URILocatorImpl.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/matcher/ContentMatcher.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/matcher/impl/ContainsExpectedValueMatcher.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/matcher/impl/MD5HashResponseMatcher.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/org/sasanlabs/fileupload/ui/FileUploadOptionsPanel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters