Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 2, 2025

What kind of changes does this PR include?

  • Fixes or refactors
  • A new challenge
  • Additional documentation
  • Something else

Description

The dead link checker was failing due to 141+ invalid GitHub URLs using the www subdomain, which doesn't exist for github.com, and lychee attempting to validate internal application routes.

Changes:

  • Fixed https://www.github.com/https://github.com/ across:
    • src/main/resources/templates/welcome.html (48 URLs)
    • static-site/pr-2125/pages/welcome.html (48 URLs)
    • README.md (45+ URLs in contributors + LinkedIn share link)
  • Added Docker Hub exclusion to .lycheeignore (returns 403 Forbidden)
  • Added regex pattern ^/[^/].* to .lycheeignore to exclude internal application routes (e.g., /challenge/challenge-1, /images/screenshot.png) from link validation

Impact:
Link checker errors reduced from 248 to 112. The InvalidPathToUri warnings for internal routes are now eliminated by excluding them from validation.

Relations

Closes #2338

References

N/A

Checklist:

  • All the contributions made are solely the work of me and my co-authors
  • I used AI to generate parts of the content.
  • I tested the changes in this PR (if applicable)
  • I added unit tests to ensure my change works (when change in Java or on front-end code)
  • I added UI tests to ensure my UI changes work (when change in the overall UI, not needed if just adding a challenge)
  • The PR passes pre-commit hooks and automated tests
Original prompt

This section details on the original issue you should resolve

<issue_title>The dead link checker is failing</issue_title>
<issue_description>The dead link checker is failing, can you please fix it?</issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI changed the title [WIP] Fix failure in dead link checker Fix dead link checker: correct www.github.com URLs Dec 2, 2025
Copilot AI requested a review from commjoen December 2, 2025 09:11
@github-actions
Copy link

github-actions bot commented Dec 2, 2025

🌐 GitHub Pages Preview Ready!

Your static preview is now available at:
🔗 Preview PR #2339

📄 What's included:

For full functionality testing: Use the Docker preview instead.

🔄 Auto-updates: This preview will be updated automatically when you push new commits to this PR.


Static preview with Thymeleaf generation by GitHub Actions

@commjoen
Copy link
Collaborator

commjoen commented Dec 2, 2025

@copilot we stil get
[WARN ] Error creating request: InvalidPathToUri("/images/screenshot.png")
[WARN ] Error creating request: InvalidPathToUri("/Dockerfile")
[WARN ] Error creating request: InvalidPathToUri("/Dockerfile.web")
[WARN ] Error creating request: InvalidPathToUri("/k8s/")
[WARN ] Error creating request: InvalidPathToUri("/okteto/")
[WARN ] Error creating request: InvalidPathToUri("/gcp/k8s-vault-gcp-ingress-start.sh")
[WARN ] Error creating request: InvalidPathToUri("/src/main/java/org/owasp/wrongsecrets/challenges/docker/Challenge15.java")
[WARN ] Error creating request: InvalidPathToUri("/aws/k8s/secret-challenge-vault-deployment.yml")
[WARN ] Error creating request: InvalidPathToUri("/gcp/k8s/secret-challenge-vault-deployment.yml.tpl")
[WARN ] Error creating request: InvalidPathToUri("/.github/workflows/scanner-comparison.yml")
[WARN ] Error creating request: InvalidPathToUri("/docs/scanner-comparison.md")
[WARN ] Error creating request: InvalidPathToUri("/ctf-instructions.md")
[WARN ] Error creating request: InvalidPathToUri("/CONTRIBUTING.md")
[WARN ] Error creating request: InvalidPathToUri("/")
[WARN ] Error creating request: InvalidPathToUri("/")
[WARN ] Error creating request: InvalidPathToUri("/")
[WARN ] Error creating request: InvalidPathToUri("/")
[WARN ] Error creating request: InvalidPathToUri("/stats")
[WARN ] Error creating request: InvalidPathToUri("/stats")
[WARN ] Error creating request: InvalidPathToUri("/about")
[WARN ] Error creating request: InvalidPathToUri("/v3/api-docs")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-1")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-2")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-3")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-4")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-5")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-6")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-7")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-8")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-9")
[WARN ] Error creating request: InvalidPathToUri("/challenge/challenge-10")

Summary

Status Count
🔍 Total 697
✅ Successful 383
⏳ Timeouts 0
🔀 Redirected 0
👻 Excluded 313
❓ Unknown 0
🚫 Errors 1
⛔ Unsupported 0
in https://github.com/OWASP/wrongsecrets/actions/runs/19853130288/job/56885653118?pr=2339

Copy link
Contributor Author

Copilot AI commented Dec 2, 2025

@copilot we stil get
[WARN ] Error creating request: InvalidPathToUri("/images/screenshot.png")
[WARN ] Error creating request: InvalidPathToUri("/Dockerfile")
...

Fixed in commit 5cc4677. Added regex pattern ^/[^/].* to .lycheeignore to exclude internal application routes (relative paths starting with /) from link checking. This prevents the InvalidPathToUri warnings for paths like /challenge/challenge-1, /images/screenshot.png, etc.

Copilot AI changed the title Fix dead link checker: correct www.github.com URLs Fix dead link checker: correct www.github.com URLs and exclude internal routes Dec 2, 2025
@github-actions
Copy link

github-actions bot commented Dec 2, 2025

📸 Visual Diff Available!

Screenshots have been generated comparing your changes with the main branch.

Download Visual Diff Artifacts

The artifacts contain:

  • pr-home.png - Your version of the home page
  • main-home.png - Current main branch home page
  • pr-about.png - Your version of the about page
  • main-about.png - Current main branch about page

Compare these images to see the visual impact of your changes!


Visual diff generated by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

🔨 Preview Build Complete!

Your changes have been built and pushed to GitHub Container Registry.

🐳 Docker Image: ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-df45fe5

📦 Download & Test Locally:

  1. 📁 Download Docker Image Artifact (look for wrongsecrets-preview-pr-2339)
  2. Load and run the image:
# Download the artifact, extract it, then:
docker load < wrongsecrets-preview.tar
docker run -p 8080:8080 wrongsecrets-preview

🚀 Alternative - Pull from Registry:

docker pull ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-df45fe5
docker run -p 8080:8080 ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-df45fe5

Then visit: http://localhost:8080

📝 Changes in this PR:
- src/main/resources/templates/welcome.html

Visual diff screenshots will be available shortly...


Preview built by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

📸 Visual Diff Ready!

Screenshots comparing your changes with the main branch are available:

📁 Download Visual Diff Artifacts

🖼️ Included screenshots:

  • pr-home.png vs main-home.png - Welcome page comparison
  • pr-about.png vs main-about.png - About page comparison
  • pr-challenge.png vs main-challenge.png - Challenge page comparison

🔍 How to review:

  1. Download the artifact zip file
  2. Extract and compare the pr-* and main-* images side by side
  3. Look for visual differences in layout, styling, and content

💡 Tip: Use an image comparison tool or open both images in separate browser tabs to spot differences easily.


Visual diff generated by GitHub Actions • PR #2339

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

🌐 GitHub Pages Preview Ready!

Your static preview is now available at:
🔗 Preview PR #2339

📄 What's included:

For full functionality testing: Use the Docker preview instead.

🔄 Auto-updates: This preview will be updated automatically when you push new commits to this PR.


Static preview with Thymeleaf generation by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

📸 Visual Diff Available!

Screenshots have been generated comparing your changes with the main branch.

Download Visual Diff Artifacts

The artifacts contain:

  • pr-home.png - Your version of the home page
  • main-home.png - Current main branch home page
  • pr-about.png - Your version of the about page
  • main-about.png - Current main branch about page

Compare these images to see the visual impact of your changes!


Visual diff generated by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

📸 Visual Diff Available!

Screenshots have been generated comparing your changes with the main branch.

Download Visual Diff Artifacts

The artifacts contain:

  • pr-home.png - Your version of the home page
  • main-home.png - Current main branch home page
  • pr-about.png - Your version of the about page
  • main-about.png - Current main branch about page

Compare these images to see the visual impact of your changes!


Visual diff generated by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

🔨 Preview Build Complete!

Your changes have been built and pushed to GitHub Container Registry.

🐳 Docker Image: ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-79c03c0

📦 Download & Test Locally:

  1. 📁 Download Docker Image Artifact (look for wrongsecrets-preview-pr-2339)
  2. Load and run the image:
# Download the artifact, extract it, then:
docker load < wrongsecrets-preview.tar
docker run -p 8080:8080 wrongsecrets-preview

🚀 Alternative - Pull from Registry:

docker pull ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-79c03c0
docker run -p 8080:8080 ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-79c03c0

Then visit: http://localhost:8080

📝 Changes in this PR:
- src/main/resources/templates/welcome.html

Visual diff screenshots will be available shortly...


Preview built by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

🔨 Preview Build Complete!

Your changes have been built and pushed to GitHub Container Registry.

🐳 Docker Image: ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-79c03c0

📦 Download & Test Locally:

  1. 📁 Download Docker Image Artifact (look for wrongsecrets-preview-pr-2339)
  2. Load and run the image:
# Download the artifact, extract it, then:
docker load < wrongsecrets-preview.tar
docker run -p 8080:8080 wrongsecrets-preview

🚀 Alternative - Pull from Registry:

docker pull ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-79c03c0
docker run -p 8080:8080 ghcr.io/owasp/wrongsecrets/wrongsecrets-pr:pr-2339-79c03c0

Then visit: http://localhost:8080

📝 Changes in this PR:
- src/main/resources/templates/welcome.html

Visual diff screenshots will be available shortly...


Preview built by GitHub Actions

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

📸 Visual Diff Ready!

Screenshots comparing your changes with the main branch are available:

📁 Download Visual Diff Artifacts

🖼️ Included screenshots:

  • pr-home.png vs main-home.png - Welcome page comparison
  • pr-about.png vs main-about.png - About page comparison
  • pr-challenge.png vs main-challenge.png - Challenge page comparison

🔍 How to review:

  1. Download the artifact zip file
  2. Extract and compare the pr-* and main-* images side by side
  3. Look for visual differences in layout, styling, and content

💡 Tip: Use an image comparison tool or open both images in separate browser tabs to spot differences easily.


Visual diff generated by GitHub Actions • PR #2339

@github-actions
Copy link

github-actions bot commented Dec 2, 2025

📸 Visual Diff Ready!

Screenshots comparing your changes with the main branch are available:

📁 Download Visual Diff Artifacts

🖼️ Included screenshots:

  • pr-home.png vs main-home.png - Welcome page comparison
  • pr-about.png vs main-about.png - About page comparison
  • pr-challenge.png vs main-challenge.png - Challenge page comparison

🔍 How to review:

  1. Download the artifact zip file
  2. Extract and compare the pr-* and main-* images side by side
  3. Look for visual differences in layout, styling, and content

💡 Tip: Use an image comparison tool or open both images in separate browser tabs to spot differences easily.


Visual diff generated by GitHub Actions • PR #2339

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

🧹 Preview Cleanup Complete

The static preview for this PR has been removed from GitHub Pages.

Thanks for contributing to WrongSecrets! 🎉


Cleanup completed by GitHub Actions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The dead link checker is failing

2 participants