6#ifndef CSRFPROTECTION_H
7#define CSRFPROTECTION_H
9#include <Cutelyst/Plugin>
10#include <Cutelyst/cutelyst_global.h>
15class CSRFProtectionPrivate;
264 void setDefaultDetachTo(
const QString &actionNameOrPath);
270 void setFormFieldName(
const QByteArray &fieldName);
276 void setErrorMsgStashKey(
const QString &keyName);
283 void setIgnoredNamespaces(
const QStringList &namespaces);
292 void setUseSessions(
bool useSessions);
310 void setCookieHttpOnly(
bool httpOnly);
317 void setCookieName(
const QByteArray &cookieName);
323 void setHeaderName(
const QByteArray &headerName);
331 void setGenericErrorMessage(
const QString &message);
338 void setGenericErrorContentType(
const QByteArray &type);
368 static bool checkPassed(
Context *c);
374 const std::unique_ptr<CSRFProtectionPrivate> d_ptr;
The Cutelyst application.
Protect input forms against Cross Site Request Forgery (CSRF/XSRF) attacks.
~CSRFProtection() override
Base class for Cutelyst Plugins.
The Cutelyst namespace holds all public Cutelyst API.