Control Unified Search availability through Policy Workbench
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 22/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- php, typescript
- Domain
- authorization, backend, frontend, search
Research direction
Start with the policy framework in lib/Service/Policy/PolicyService.php and lib/Service/Policy/Provider/PolicyProviders.php, then read lib/Service/Policy/Provider/Confetti/ConfettiPolicy.php as the model for a boolean policy. The search side is FileSearchProvider::getOrder() and its search() method, and the settings UI is in src/views/Settings/PolicyWorkbench/settings/realDefinitions.ts. Done means a disabled policy hides the provider and returns an empty completed result for direct searches, with PHP and frontend tests covering allowed and denied states; coordinate with #8916 on system default enforcement first.
Written by the indexing model from the issue text.
Description
Goal
Allow administrators to control the availability of LibreSign documents in Nextcloud Unified Search through the existing Policy Workbench.
Proposed policy contract
- Key:
search_provider_enabled - Type: boolean
- Default: enabled
- Lifecycle: runtime
- Scopes: system, group and user
- Request-level override: unsupported
- Delegation and inheritance: existing LibreSign policy framework
The final implementation must remain consistent with #8916, which addresses explicit system policies that enforce their default value.
Backend
- Register the policy through the existing policy providers.
- Resolve policy state for the effective authenticated user.
- Respect Nextcloud's global provider controls.
- Change
FileSearchProvider::getOrder()to support returningnullwhen the provider should be hidden. - Enforce availability independently in
search()using theIUsersupplied by Nextcloud. - A disabled policy must prevent document queries and return an empty completed result.
- Direct requests must not bypass the policy.
- Policy failures must not disclose unauthorized results.
- Disabling search must not change underlying document permissions or LibreSign internal lists.
Frontend
Use the existing Policy Workbench under System behavior.
Proposed setting title: LibreSign search results
Description: Control whether LibreSign documents appear in Nextcloud Unified Search. This does not change document permissions or internal LibreSign file lists.
Reuse existing boolean rule editors, inheritance behavior, permissions and save/reset actions.
Starting points
lib/Service/Policy/Provider/Confetti/ConfettiPolicy.phplib/Service/Policy/Provider/PolicyProviders.phplib/Service/Policy/PolicyService.phpsrc/views/Settings/PolicyWorkbench/settings/confetti/realDefinition.tssrc/views/Settings/PolicyWorkbench/settings/realDefinitions.ts
Acceptance criteria
- Default, enabled, disabled, inherited and explicitly enforced policy states work.
- Only authorized administrators can modify the relevant rules.
- Provider discovery reflects the effective policy.
- Direct provider searches enforce the same policy.
- Existing Nextcloud provider restrictions are respected.
- Document permissions and signing workflows are unchanged.
- PHP and frontend tests cover allowed and denied behavior.
- The interface is accessible and translated.
- The PR includes a screenshot or short video without sensitive data.
- User/admin documentation is updated through the documentation work.
- Dominant language
- PHP
- Stars
- 828
- Forks
- 159
- Avg merge
- 7h 53m
- Merged PRs (30d)
- 523
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from LibreSign/libresign
-
Difficulty 1/5 Under an hour Newbie friendliness 83/100
LibreSign/libresign#9007 · 1 reaction ·
Maintainers usually reply within 1 day
-
backend enhancement php
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Validation page says "This document is valid" for a document with no signaturePossibly taken @maia-andre claimed this 9 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
LibreSign/libresign#8284 · 5 comments ·
Maintainers usually reply within 1 day
-
backend php
Difficulty 4/5 3-5 days Newbie friendliness 48/100
Maintainers usually reply within 1 day
All issues in LibreSign/libresign
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Do not throw `WordPress.Security.EscapeOutput.OutputNotEscaped` on `apply_shortcodes()`Possibly taken @tbradsha claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
fe: spell out "Auto increment" in the table editor, "AI" reads as artificial intelligence todayOpen
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
landsman/adminer-desktop#120 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
components-web-app/docs#227 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100