Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrReqWithoutExpiresKey = fmt.Errorf("bad req: without expires key") ErrReqInvalidExpiresValue = fmt.Errorf("bad req: invalid expires val") ErrReqWithoutChecksumKey = fmt.Errorf("bad req: without checksum key") ErrReqInvalidChecksum = fmt.Errorf("bad req: invalid checksum key") ErrReqExpired = fmt.Errorf("req overdue") )
Functions ¶
This section is empty.
Types ¶
type Checker ¶
type Checker struct { Config *CheckerConfig // contains filtered or unexported fields }
type CheckerConfig ¶
type CheckerConfig struct { ChecksumKey string ExpiresKey string ExpressionNodes []ExpressionNodeFile }
type ConfModSecureLink ¶
type Data ¶
type Data struct { Version string // version of the config Config ProductRules // product rules for header }
type DataFile ¶
type DataFile struct { Version *string // version of the config Config ProductRulesFile }
type Expression ¶
type Expression struct {
// contains filtered or unexported fields
}
func NewExpression ¶
func NewExpression(cc *CheckerConfig) (*Expression, error)
type ExpressionNode ¶
func NewNode ¶
func NewNode(enf ExpressionNodeFile) (ExpressionNode, error)
type ExpressionNodeFile ¶
type ModuleSecureLink ¶
type ModuleSecureLink struct {
// contains filtered or unexported fields
}
ModuleSecureLink mean secure link module
func NewModuleSecureLink ¶
func NewModuleSecureLink() *ModuleSecureLink
NewModuleSecureLink create module
func (*ModuleSecureLink) Init ¶
func (m *ModuleSecureLink) Init(cbs *bfe_module.BfeCallbacks, whs *web_monitor.WebHandlers, cr string) error
Init init mode, will be invoked by framework
type ModuleSecureLinkState ¶
type ModuleSecureLinkState struct { ReqTotal *metrics.Counter // all request in ReqAccept *metrics.Counter // request accept ReqWithoutExpiresKey *metrics.Counter ReqInvalidExpiresValue *metrics.Counter ReqWithoutChecksumKey *metrics.Counter ReqInvalidChecksum *metrics.Counter ReqExpired *metrics.Counter }
type NodeConfig ¶
type ProductRules ¶
type ProductRulesFile ¶
type Rule ¶
type RuleFile ¶
type RuleFile struct { Cond *string ChecksumKey *string ExpiresKey *string ExpressionNodes []ExpressionNodeFile }
RuleFile define how to validate secure link
type SecureLinkTable ¶
type SecureLinkTable struct {
// contains filtered or unexported fields
}
func NewSecureLinkTable ¶
func NewSecureLinkTable() *SecureLinkTable
func (*SecureLinkTable) Update ¶
func (t *SecureLinkTable) Update(conf *Data)
Click to show internal directories.
Click to hide internal directories.