Skip to content

Disallow slugs from having slashes or FQDN's in them - #645

Merged
JackLewis-digirati merged 4 commits into
developfrom
fix/slashesInSlugs
Aug 7, 2026
Merged

Disallow slugs from having slashes or FQDN's in them#645
JackLewis-digirati merged 4 commits into
developfrom
fix/slashesInSlugs

Conversation

@JackLewis-digirati

@JackLewis-digirati JackLewis-digirati commented Aug 4, 2026

Copy link
Copy Markdown
Collaborator

What does this change?

Resolves #571

Makes it so slugs aren't allowed to have FQDN's or forward slashes. This is also extendable, due to adding a setting controlling characters that are disallowed from use in slugs.

Configuration Changes

Note

This PR introduces configuration changes.

Service AppSetting Required? Description Default
API ApiSettings:ProhibitedSlugCharacters N Prohibited characters in the slug ["/"]

@JackLewis-digirati
JackLewis-digirati marked this pull request as ready for review August 4, 2026 09:48
@JackLewis-digirati
JackLewis-digirati requested a review from a team as a code owner August 4, 2026 09:48

@donaldgray donaldgray left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Service AppSetting Required? Description Default
API ApiSettings:ProhibitedSlugCharacters Y Prohibited characters in the slug ["/"]

I think "Required?" should be N for this. It's not required as it has a default, and (untested) it looks like if you set it to an empty array it'd just let through every character.

Comment thread src/IIIFPresentation/API/Settings/ApiSettings.cs
@JackLewis-digirati

Copy link
Copy Markdown
Collaborator Author

Changed Required to be N following discussion

@JackLewis-digirati
JackLewis-digirati merged commit dc789c5 into develop Aug 7, 2026
4 checks passed
@JackLewis-digirati
JackLewis-digirati deleted the fix/slashesInSlugs branch August 7, 2026 13:45
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.

Slugs can contain forward slashes/FQDNs

2 participants