Package jenkins.security.csp
Class SimpleContributor
java.lang.Object
jenkins.security.csp.SimpleContributor
- All Implemented Interfaces:
ExtensionPoint,Contributor
@Restricted(org.kohsuke.accmod.restrictions.Beta.class)
public abstract class SimpleContributor
extends Object
implements Contributor
Convenient base class for CSP contributors only adding individual domains to a fetch directive.
Plugins may need to do this, likely for
img-src, to allow loading avatars and similar resources.- Since:
- TODO
-
Nested Class Summary
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidallow(FetchDirective directive, String... domain) final voidapply(CspBuilder cspBuilder) Contribute to the builder's rules by adding to or removing from the providedCspBuilder.
-
Constructor Details
-
SimpleContributor
public SimpleContributor()
-
-
Method Details
-
allow
-
apply
Description copied from interface:ContributorContribute to the builder's rules by adding to or removing from the providedCspBuilder.- Specified by:
applyin interfaceContributor- Parameters:
cspBuilder- the builder
-