Skip to content

Fix URL signing api for URLs containing special characters#12435

Open
ErykKul wants to merge 10 commits into
developfrom
fix-url-signing-special-characters
Open

Fix URL signing api for URLs containing special characters#12435
ErykKul wants to merge 10 commits into
developfrom
fix-url-signing-special-characters

Conversation

@ErykKul

@ErykKul ErykKul commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

What this PR does / why we need it:
Bug fix; URL signing for URLs containing special characters broken in 6.10, this PR fixes the introduced bug.

Which issue(s) this PR closes:
Issue not created, bug fixed directly here.

Special notes for your reviewer:
Added tests to prevent regression. Also, API requires now the signing secret to be set, otherwise it will not work.

Suggestions on how to test this:
No special testing needed, the unit tests should be sufficient.

Does this PR introduce a user interface change? If mockups are available, please link/include them here:
No

Is there a release notes update needed for this change?:
Yes, included.

Additional documentation:
No

@ErykKul ErykKul added Size: 3 A percentage of a sprint. 2.1 hours. Type: Bug - Blocker Bug is blocking user work, no workaround available labels Jun 4, 2026
@ErykKul ErykKul added this to the 6.11 milestone Jun 4, 2026
@ErykKul ErykKul moved this to Ready for Review ⏩ in IQSS Dataverse Project Jun 4, 2026
@coveralls

coveralls commented Jun 4, 2026

Copy link
Copy Markdown

Coverage Status

coverage: 25.029% (+0.004%) from 25.025% — fix-url-signing-special-characters into develop

@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@ErykKul ErykKul moved this from Ready for Review ⏩ to In Progress 💻 in IQSS Dataverse Project Jun 4, 2026
@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown

Test Results

403 tests  ±0   388 ✅ ±0   38m 0s ⏱️ + 4m 23s
 55 suites ±0    15 💤 ±0 
 55 files   ±0     0 ❌ ±0 

Results for commit 4bbb576. ± Comparison against base commit 670f82f.

♻️ This comment has been updated with latest results.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

Comment thread doc/sphinx-guides/source/installation/config.rst
@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

@pdurbin pdurbin removed this from the 6.11 milestone Jun 8, 2026
@pdurbin pdurbin added this to the 6.12 milestone Jun 8, 2026
@pdurbin pdurbin moved this from In Progress 💻 to Ready for Review ⏩ in IQSS Dataverse Project Jun 8, 2026
@pdurbin

pdurbin commented Jun 8, 2026

Copy link
Copy Markdown
Member

@ErykKul sorry, we bumped this to 6.12 given our capacity and how you said you're probably the only person using this API. 😄

@stevenwinship stevenwinship self-assigned this Jun 15, 2026
@stevenwinship stevenwinship moved this from Ready for Review ⏩ to In Review 🔎 in IQSS Dataverse Project Jun 15, 2026
return error(Response.Status.INTERNAL_SERVER_ERROR,
"Requesting signed URLs requires a signing secret to be configured. Please set the dataverse.api.signing-secret JVM option.");
}

@stevenwinship stevenwinship Jun 15, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

My concern with this being here is that it doesn't cover the URL signing when requesting a file download with a guestbook response. Those APIs still work without the secret. (See Access.java) These APIs all call UrlSignerUtil.signUrl, which should have this code to return an error if no signing-secret exists.

{
"status": "OK",
"data": {
"signedUrl": "http://localhost:8080/api/v1/access/dataset/4?gbrecs=true&gbrids=12&until=2026-06-15T20:36:32.302&user=usere7c863fd&method=GET&token=c99c3f9393be5ddedbd72829b6a8b29de3310b06f6692b77286351ba079c82af177c0e8c8df237afe7d6611b7c044e79cc7e402042bf07aa1f9cbbb9cf855298"
}
}

@github-actions

Copy link
Copy Markdown

📦 Pushed preview images as

ghcr.io/gdcc/dataverse:fix-url-signing-special-characters
ghcr.io/gdcc/configbaker:fix-url-signing-special-characters

🚢 See on GHCR. Use by referencing with full name as printed above, mind the registry name.

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

Labels

Size: 3 A percentage of a sprint. 2.1 hours. Type: Bug - Blocker Bug is blocking user work, no workaround available

Projects

Status: In Review 🔎

Development

Successfully merging this pull request may close these issues.

4 participants