Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Engine ¶
type Engine struct {
// contains filtered or unexported fields
}
Engine drives policy management.
func DefaultAuthPolicy ¶
DefaultAuthPolicy returns the default policy engine
func NewEngineFromConfigOrDefault ¶
func NewEngineFromConfigOrDefault(ctx context.Context, logger logrus.FieldLogger, cfg *OpaEngineConfig) (*Engine, error)
NewEngineFromConfigOrDefault returns a new policy engine. Or if no config is provided, provides the default policy
type Input ¶
type Input struct {
// Caller is the authenticated identity of the actor making a request.
Caller string `json:"caller"`
// FullMethod is the fully-qualified name of the proto rpc service method.
FullMethod string `json:"full_method"`
// Req represents data received from the request body. It MUST be a
// protobuf request object with fields that are serializable as JSON,
// since they will be used in policy definitions.
Req any `json:"req"`
}
Input represents context associated with an access request.
type LocalOpaProviderConfig ¶
type OpaEngineConfig ¶
type OpaEngineConfig struct {
LocalOpaProvider *LocalOpaProviderConfig `hcl:"local"`
}
Click to show internal directories.
Click to hide internal directories.