Class TestCrumbIssuer

java.lang.Object
hudson.security.csrf.CrumbIssuer
org.jvnet.hudson.test.TestCrumbIssuer
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<hudson.security.csrf.CrumbIssuer>

public class TestCrumbIssuer extends hudson.security.csrf.CrumbIssuer
A crumb issuer that issues a constant crumb value. Used for unit testing.
Author:
dty
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
     

    Nested classes/interfaces inherited from class hudson.security.csrf.CrumbIssuer

    hudson.security.csrf.CrumbIssuer.RestrictedApi

    Nested classes/interfaces inherited from interface hudson.ExtensionPoint

    hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson
  • Field Summary

    Fields inherited from class hudson.security.csrf.CrumbIssuer

    DEFAULT_CRUMB_NAME
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected String
    issueCrumb(javax.servlet.ServletRequest request, String salt)
     
    boolean
    validateCrumb(javax.servlet.ServletRequest request, String salt, String crumb)
     

    Methods inherited from class hudson.security.csrf.CrumbIssuer

    all, getApi, getCrumb, getCrumb, getCrumbRequestField, getDescriptor, initStaplerCrumbIssuer, validateCrumb, validateCrumb

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TestCrumbIssuer

      @DataBoundConstructor public TestCrumbIssuer()
  • Method Details

    • issueCrumb

      protected String issueCrumb(javax.servlet.ServletRequest request, String salt)
      Specified by:
      issueCrumb in class hudson.security.csrf.CrumbIssuer
    • validateCrumb

      public boolean validateCrumb(javax.servlet.ServletRequest request, String salt, String crumb)
      Specified by:
      validateCrumb in class hudson.security.csrf.CrumbIssuer