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

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

Best Java code snippets using org.apache.wicket.protocol.http.CsrfPreventionRequestCycleListener.onMatchingOrigin (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 was checked and matched the request origin. 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 matchingOrigin(HttpServletRequest request, String origin,
  IRequestablePage page)
{
  onMatchingOrigin(request, origin, page);
  if (log.isDebugEnabled())
  {
    log.debug("CSRF Origin {} matched requested resource, allowed for page {}", origin,
      page.getClass().getName());
  }
}
origin: org.apache.wicket/wicket-core

/**
 * Handles the case where an origin was checked and matched the request origin. 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 matchingOrigin(HttpServletRequest request, String origin,
  IRequestablePage page)
{
  onMatchingOrigin(request, origin, page);
  if (log.isDebugEnabled())
  {
    log.debug("CSRF Origin {} matched requested resource, allowed for page {}", origin,
      page.getClass().getName());
  }
}
org.apache.wicket.protocol.httpCsrfPreventionRequestCycleListeneronMatchingOrigin

Javadoc

Called when the origin HTTP header matched the request. 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,
  • onSuppressed,
  • onWhitelisted,
  • setConflictingOriginAction,
  • setErrorCode

Popular in Java

  • Updating database using SQL prepared statement
  • getSystemService (Context)
  • addToBackStack (FragmentTransaction)
  • orElseThrow (Optional)
  • Container (java.awt)
    A generic Abstract Window Toolkit(AWT) container object is a component that can contain other AWT co
  • IOException (java.io)
    Signals that an I/O exception of some sort has occurred. This class is the general class of exceptio
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • MessageFormat (java.text)
    MessageFormat provides a means to produce concatenated messages in language-neutral way. Use this to
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
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