-
Notifications
You must be signed in to change notification settings - Fork 7
Admin UI for adding external hosts to a variety of directives #6359
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
Merged
Merged
Changes from all commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
76e5337
Admin UI for adding external hosts to a variety of directives
labkey-adam 83aa1cb
Reduce per-request work for CSP filter to a single substitution. Impr…
labkey-adam 32d43fa
Checkpoint - persistence, initialization, and add new hosts
labkey-adam b4802e3
Checkpoint - list existing hosts, upgrade code
labkey-adam 41519f3
Checkpoint - delete
labkey-adam 91fdc75
Checkpoint - edit
labkey-adam 627d94e
Substitution -> AllowedHost
labkey-adam a10d0b9
Upgrade code to migrate old properties
labkey-adam 212c71d
Startup properties
labkey-adam 06ca71a
Report CSP status (enforce CSP & expected substitutions in place). Ha…
labkey-adam 49e0a0c
Turn CSP_FILTERS into a Map. Attempt to determine cspVersion of each …
labkey-adam 4d21dd2
Merge remote-tracking branch 'origin/develop' into fb_admin_csp_sources
labkey-adam 6e09508
Update comment
labkey-adam 5b1f3d8
Clarify ambiguous name to CaseInsensitiveKeyedHashSetValuedMap. Add n…
labkey-adam 5ad6d32
When adding new hosts, persist the most recent directive in the drop-…
labkey-adam 42bc5c1
Merge remote-tracking branch 'origin/develop' into fb_admin_csp_sources
labkey-adam 4ed5703
Add the actual policy (substituted and not) to metrics
labkey-adam 7d270ee
Behold the super sophisticated CSP parser
labkey-adam 7e69abc
No semicolons
labkey-adam ce04d6c
App admins can edit allowed external resource hosts, allowed redirect…
labkey-adam cfdd51d
Validate incoming startup properties as well
labkey-adam ece47c7
Merge remote-tracking branch 'origin/develop' into fb_admin_csp_sources
labkey-adam 9036e36
Update core/src/org/labkey/core/security/AllowedExternalResourceHosts…
labkey-adam 446e8ee
Update core/src/org/labkey/core/admin/AdminController.java
labkey-adam a72fba1
Core review feedback
labkey-adam 17a6a1d
Link to CSP configuration docs page
labkey-adam bc6a058
Merge remote-tracking branch 'origin/develop' into fb_admin_csp_sources
labkey-adam 239d01f
Merge remote-tracking branch 'origin/develop' into fb_admin_csp_sources
labkey-adam File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
api/src/org/labkey/api/collections/CaseInsensitiveKeyedHashSetValuedMap.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,38 @@ | ||
| /* | ||
| * Copyright (c) 2016 LabKey Corporation | ||
| * | ||
| * Licensed under the Apache License, Version 2.0 (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * | ||
| * http://www.apache.org/licenses/LICENSE-2.0 | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, | ||
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| package org.labkey.api.collections; | ||
|
|
||
| import org.apache.commons.collections4.multimap.AbstractSetValuedMap; | ||
|
|
||
| import java.util.HashSet; | ||
| import java.util.Set; | ||
|
|
||
| /** | ||
| * An org.apache.commons.collections4.multimap.HashSetValuedHashMap with case-insensitive String keys | ||
| */ | ||
| public class CaseInsensitiveKeyedHashSetValuedMap<V> extends AbstractSetValuedMap<String, V> implements CaseInsensitiveCollection | ||
| { | ||
| public CaseInsensitiveKeyedHashSetValuedMap() | ||
| { | ||
| super(new CaseInsensitiveHashMap<>()); | ||
| } | ||
|
|
||
| @Override | ||
| protected Set<V> createCollection() | ||
| { | ||
| return new HashSet<>(); | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.