HttpUpgradeProtocolAccess.h
Go to the documentation of this file.
65 template <typename Visitor> inline void forApplicable(const ProtocolView &, const Visitor &) const;
106HttpUpgradeProtocolAccess::forApplicable(const ProtocolView &offer, const Visitor &visitor) const
bool vAinB(const ProtocolView &a, const ProtocolView &b)
Definition: HttpUpgradeProtocolAccess.h:38
std::ostream & operator<<(std::ostream &, const ProtocolView &)
Definition: HttpUpgradeProtocolAccess.cc:34
Definition: ConfigParser.h:46
a single configured access rule for an explicitly named protocol
Definition: HttpUpgradeProtocolAccess.h:70
NamedGuard(const NamedGuard &&)=delete
NamedGuard(const char *rawProtocol, acl_access *)
Definition: HttpUpgradeProtocolAccess.cc:71
~NamedGuard()
Definition: HttpUpgradeProtocolAccess.cc:78
const ProtocolView proto
optimization: compiled this->protocol
Definition: HttpUpgradeProtocolAccess.h:77
Allows or blocks HTTP Upgrade protocols (see http_upgrade_request_protocols)
Definition: HttpUpgradeProtocolAccess.h:48
void configureGuard(ConfigParser &)
parses a single allow/deny rule
Definition: HttpUpgradeProtocolAccess.cc:50
HttpUpgradeProtocolAccess(HttpUpgradeProtocolAccess &&)=delete
~HttpUpgradeProtocolAccess()
Definition: HttpUpgradeProtocolAccess.cc:44
const acl_access * findGuard(const SBuf &proto) const
std::deque< NamedGuard > NamedGuards
maps HTTP Upgrade protocol name/version to the ACLs guarding its usage
Definition: HttpUpgradeProtocolAccess.h:82
acl_access * other
OTHER rules governing unnamed protocols.
Definition: HttpUpgradeProtocolAccess.h:91
void forEach(const Visitor &) const
iterates over all configured rules, calling the given visitor
Definition: HttpUpgradeProtocolAccess.h:96
void forApplicable(const ProtocolView &, const Visitor &) const
Definition: HttpUpgradeProtocolAccess.h:106
static const SBuf ProtoOther
pseudonym to specify rules for "all other protocols"
Definition: HttpUpgradeProtocolAccess.h:85
NamedGuards namedGuards
rules governing upgrades to explicitly named protocols
Definition: HttpUpgradeProtocolAccess.h:88
HttpUpgradeProtocolAccess()=default
a reference to a protocol name[/version] string; no 0-termination is assumed
Definition: HttpUpgradeProtocolAccess.h:20
ProtocolView(const char *const start, const size_t len)
Definition: HttpUpgradeProtocolAccess.cc:22
SBuf version
everything after the name, including the slash('/')
Definition: HttpUpgradeProtocolAccess.h:26
SBuf name
everything up to (but excluding) the first slash('/')
Definition: HttpUpgradeProtocolAccess.h:25