Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hardening suggestions for Stirling-PDF / 2270-feature-request-external-db-support #2459

Open
wants to merge 1 commit into
base: 2270-feature-request-external-db-support
Choose a base branch
from

Conversation

pixeebot[bot]
Copy link
Contributor

@pixeebot pixeebot bot commented Dec 15, 2024

I've reviewed the recently opened PR (2457 - #2270: External DB Support) and have identified some area(s) that could benefit from additional hardening measures.

These changes should help prevent potential security vulnerabilities and improve overall code quality.

Thank you for your consideration!
🧚🤖 Powered by Pixeebot

Feedback | Community | Docs

@pixeebot pixeebot bot requested a review from Frooodle as a code owner December 15, 2024 13:28
@pixeebot pixeebot bot requested a review from DarioGii December 15, 2024 13:28
@@ -93,7 +93,7 @@ public static boolean isURLReachable(String urlStr) {

// Allow only http and https protocols
String protocol = url.getProtocol();
if (!protocol.equals("http") && !protocol.equals("https")) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Switch order of literals to prevent NullPointerException

@@ -93,7 +93,7 @@ public static boolean isURLReachable(String urlStr) {

// Allow only http and https protocols
String protocol = url.getProtocol();
if (!protocol.equals("http") && !protocol.equals("https")) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Switch order of literals to prevent NullPointerException

@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Dec 15, 2024
@github-actions github-actions bot added the Java Pull requests that update Java code label Dec 15, 2024
@pixeebot pixeebot bot force-pushed the pixeebot/2270-feature-request-external-db-support branch 2 times, most recently from e7ea6f2 to e370adb Compare December 15, 2024 13:30
@pixeebot pixeebot bot force-pushed the pixeebot/2270-feature-request-external-db-support branch from e370adb to 489e54d Compare December 15, 2024 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Java Pull requests that update Java code size:XS This PR changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants