Codota Logo
CsrfPreventionRequestCycleListener.onWhitelisted
Code IndexAdd Codota to your IDE (free)

How to use
onWhitelisted
method
in
org.apache.wicket.protocol.http.CsrfPreventionRequestCycleListener

Best Java code snippets using org.apache.wicket.protocol.http.CsrfPreventionRequestCycleListener.onWhitelisted (Showing top 2 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Gson g =
  • Codota Iconnew Gson()
  • Codota IconGsonBuilder gsonBuilder;gsonBuilder.create()
  • Codota Iconnew GsonBuilder().create()
  • Smart code suggestions by Codota
}
origin: apache/wicket

/**
 * Handles the case where an origin is in the whitelist. Default action is to allow the
 * whitelisted origin.
 *
 * @param request
 *            the request
 * @param origin
 *            the contents of the {@code Origin} HTTP header
 * @param page
 *            the page that is targeted with this request
 */
protected void whitelistedHandler(HttpServletRequest request, String origin,
  IRequestablePage page)
{
  onWhitelisted(request, origin, page);
  if (log.isDebugEnabled())
  {
    log.debug("CSRF Origin {} was whitelisted, allowed for page {}", origin,
      page.getClass().getName());
  }
}
origin: org.apache.wicket/wicket-core

/**
 * Handles the case where an origin is in the whitelist. Default action is to allow the
 * whitelisted origin.
 *
 * @param request
 *            the request
 * @param origin
 *            the contents of the {@code Origin} HTTP header
 * @param page
 *            the page that is targeted with this request
 */
protected void whitelistedHandler(HttpServletRequest request, String origin,
  IRequestablePage page)
{
  onWhitelisted(request, origin, page);
  if (log.isDebugEnabled())
  {
    log.debug("CSRF Origin {} was whitelisted, allowed for page {}", origin,
      page.getClass().getName());
  }
}
org.apache.wicket.protocol.httpCsrfPreventionRequestCycleListeneronWhitelisted

Javadoc

Called when the origin was available in the whitelist. Override this method to implement your own custom action.

Popular methods of CsrfPreventionRequestCycleListener

  • <init>
  • isChecked
    Override to limit whether the request to the specific page should be checked for a possible CSRF att
  • abortHandler
    Handles the case where an Origin HTTP header was not present or did not match the request origin, an
  • addAcceptedOrigin
    Adds an origin (host name/domain name) to the white list. An origin is in the form of .<
  • allowHandler
    Handles the case where an Origin HTTP header was not present or did not match the request origin, an
  • checkRequest
    Performs the check of the Origin or Referer header that is targeted at the page.
  • getSourceUri
    Resolves the source URI from the request headers ( Origin or Referer).
  • getTargetUriFromRequest
    Creates a RFC-6454 comparable URI from the request requested resource.
  • isEnabled
    Dynamic override for enabling/disabling the CSRF detection. Might be handy for specific tenants in a
  • isLocalOrigin
    Checks whether the Origin HTTP header of the request matches where the request came from.
  • isWhitelistedHost
    Checks whether the domain part of the sourceUri ( Origin or Refererheader) is whitelisted.
  • matchingOrigin
    Handles the case where an origin was checked and matched the request origin. Default action is to al
  • isWhitelistedHost,
  • matchingOrigin,
  • normalizeUri,
  • onAborted,
  • onAllowed,
  • onMatchingOrigin,
  • onSuppressed,
  • setConflictingOriginAction,
  • setErrorCode

Popular in Java

  • Making http requests using okhttp
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • getContentResolver (Context)
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • FileInputStream (java.io)
    A FileInputStream obtains input bytes from a file in a file system. What files are available depends
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
  • JLabel (javax.swing)
  • Join (org.hibernate.mapping)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now