auth

package
v0.1.313-herb-transcode.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 16, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ReflectTypeIClaimsValidator = di.GetInterfaceReflectType((*IClaimsValidator)(nil))

ReflectTypeIClaimsValidator used when your service claims to implement IClaimsValidator

View Source
var ReflectTypeIModularAuthMiddleware = di.GetInterfaceReflectType((*IModularAuthMiddleware)(nil))

ReflectTypeIModularAuthMiddleware used when your service claims to implement IModularAuthMiddleware

Functions

func AddScopedIClaimsValidator added in v0.1.298

func AddScopedIClaimsValidator(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)

AddScopedIClaimsValidator adds a type that implements IClaimsValidator

func AddScopedIClaimsValidatorByFunc added in v0.1.298

func AddScopedIClaimsValidatorByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)

AddScopedIClaimsValidatorByFunc adds a type by a custom func

func AddScopedIClaimsValidatorByFuncWithMetadata added in v0.1.298

func AddScopedIClaimsValidatorByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddScopedIClaimsValidatorByFuncWithMetadata adds a type by a custom func

func AddScopedIClaimsValidatorWithMetadata added in v0.1.298

func AddScopedIClaimsValidatorWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddScopedIClaimsValidatorWithMetadata adds a type that implements IClaimsValidator

func AddScopedIModularAuthMiddleware

func AddScopedIModularAuthMiddleware(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)

AddScopedIModularAuthMiddleware adds a type that implements IModularAuthMiddleware

func AddScopedIModularAuthMiddlewareByFunc

func AddScopedIModularAuthMiddlewareByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)

AddScopedIModularAuthMiddlewareByFunc adds a type by a custom func

func AddScopedIModularAuthMiddlewareByFuncWithMetadata added in v0.1.217

func AddScopedIModularAuthMiddlewareByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddScopedIModularAuthMiddlewareByFuncWithMetadata adds a type by a custom func

func AddScopedIModularAuthMiddlewareWithMetadata added in v0.1.217

func AddScopedIModularAuthMiddlewareWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddScopedIModularAuthMiddlewareWithMetadata adds a type that implements IModularAuthMiddleware

func AddSingletonIClaimsValidator added in v0.1.298

func AddSingletonIClaimsValidator(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)

AddSingletonIClaimsValidator adds a type that implements IClaimsValidator

func AddSingletonIClaimsValidatorByFunc added in v0.1.298

func AddSingletonIClaimsValidatorByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)

AddSingletonIClaimsValidatorByFunc adds a type by a custom func

func AddSingletonIClaimsValidatorByFuncWithMetadata added in v0.1.298

func AddSingletonIClaimsValidatorByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddSingletonIClaimsValidatorByFuncWithMetadata adds a type by a custom func

func AddSingletonIClaimsValidatorByObj added in v0.1.298

func AddSingletonIClaimsValidatorByObj(builder *di.Builder, obj interface{}, implementedTypes ...reflect.Type)

AddSingletonIClaimsValidatorByObj adds a prebuilt obj

func AddSingletonIClaimsValidatorByObjWithMetadata added in v0.1.298

func AddSingletonIClaimsValidatorByObjWithMetadata(builder *di.Builder, obj interface{}, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddSingletonIClaimsValidatorByObjWithMetadata adds a prebuilt obj

func AddSingletonIClaimsValidatorWithMetadata added in v0.1.298

func AddSingletonIClaimsValidatorWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddSingletonIClaimsValidatorWithMetadata adds a type that implements IClaimsValidator

func AddSingletonIModularAuthMiddleware

func AddSingletonIModularAuthMiddleware(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)

AddSingletonIModularAuthMiddleware adds a type that implements IModularAuthMiddleware

func AddSingletonIModularAuthMiddlewareByFunc

func AddSingletonIModularAuthMiddlewareByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)

AddSingletonIModularAuthMiddlewareByFunc adds a type by a custom func

func AddSingletonIModularAuthMiddlewareByFuncWithMetadata added in v0.1.217

func AddSingletonIModularAuthMiddlewareByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddSingletonIModularAuthMiddlewareByFuncWithMetadata adds a type by a custom func

func AddSingletonIModularAuthMiddlewareByObj

func AddSingletonIModularAuthMiddlewareByObj(builder *di.Builder, obj interface{}, implementedTypes ...reflect.Type)

AddSingletonIModularAuthMiddlewareByObj adds a prebuilt obj

func AddSingletonIModularAuthMiddlewareByObjWithMetadata added in v0.1.217

func AddSingletonIModularAuthMiddlewareByObjWithMetadata(builder *di.Builder, obj interface{}, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddSingletonIModularAuthMiddlewareByObjWithMetadata adds a prebuilt obj

func AddSingletonIModularAuthMiddlewareWithMetadata added in v0.1.217

func AddSingletonIModularAuthMiddlewareWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddSingletonIModularAuthMiddlewareWithMetadata adds a type that implements IModularAuthMiddleware

func AddTransientIClaimsValidator added in v0.1.298

func AddTransientIClaimsValidator(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)

AddTransientIClaimsValidator adds a type that implements IClaimsValidator

func AddTransientIClaimsValidatorByFunc added in v0.1.298

func AddTransientIClaimsValidatorByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)

AddTransientIClaimsValidatorByFunc adds a type by a custom func

func AddTransientIClaimsValidatorByFuncWithMetadata added in v0.1.298

func AddTransientIClaimsValidatorByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddTransientIClaimsValidatorByFuncWithMetadata adds a type by a custom func

func AddTransientIClaimsValidatorWithMetadata added in v0.1.298

func AddTransientIClaimsValidatorWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddTransientIClaimsValidatorWithMetadata adds a type that implements IClaimsValidator

func AddTransientIModularAuthMiddleware

func AddTransientIModularAuthMiddleware(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)

AddTransientIModularAuthMiddleware adds a type that implements IModularAuthMiddleware

func AddTransientIModularAuthMiddlewareByFunc

func AddTransientIModularAuthMiddlewareByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)

AddTransientIModularAuthMiddlewareByFunc adds a type by a custom func

func AddTransientIModularAuthMiddlewareByFuncWithMetadata added in v0.1.217

func AddTransientIModularAuthMiddlewareByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddTransientIModularAuthMiddlewareByFuncWithMetadata adds a type by a custom func

func AddTransientIModularAuthMiddlewareWithMetadata added in v0.1.217

func AddTransientIModularAuthMiddlewareWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)

AddTransientIModularAuthMiddlewareWithMetadata adds a type that implements IModularAuthMiddleware

func GetIClaimsValidatorDefinition added in v0.1.298

func GetIClaimsValidatorDefinition(ctn di.Container) *di.Def

GetIClaimsValidatorDefinition returns that last definition registered that this container can provide

func GetIClaimsValidatorDefinitions added in v0.1.298

func GetIClaimsValidatorDefinitions(ctn di.Container) []*di.Def

GetIClaimsValidatorDefinitions returns all definitions that this container can provide

func GetIModularAuthMiddlewareDefinition added in v0.1.217

func GetIModularAuthMiddlewareDefinition(ctn di.Container) *di.Def

GetIModularAuthMiddlewareDefinition returns that last definition registered that this container can provide

func GetIModularAuthMiddlewareDefinitions added in v0.1.217

func GetIModularAuthMiddlewareDefinitions(ctn di.Container) []*di.Def

GetIModularAuthMiddlewareDefinitions returns all definitions that this container can provide

func RemoveAllIClaimsValidator added in v0.1.298

func RemoveAllIClaimsValidator(builder *di.Builder)

RemoveAllIClaimsValidator removes all IClaimsValidator from the DI

func RemoveAllIModularAuthMiddleware

func RemoveAllIModularAuthMiddleware(builder *di.Builder)

RemoveAllIModularAuthMiddleware removes all IModularAuthMiddleware from the DI

Types

type IClaimsValidator added in v0.1.298

type IClaimsValidator interface {
	Validate(claimsPrincipal core_contracts_claimsprincipal.IClaimsPrincipal) bool
	ValidateWithOperand(claimsPrincipal core_contracts_claimsprincipal.IClaimsPrincipal, op Operand) bool
	String() string
	StringWithOperand(op Operand) string
}

func GetIClaimsValidatorFromContainer added in v0.1.298

func GetIClaimsValidatorFromContainer(ctn di.Container) IClaimsValidator

GetIClaimsValidatorFromContainer alternative to SafeGetIClaimsValidatorFromContainer but panics of object is not present

func GetManyIClaimsValidatorFromContainer added in v0.1.298

func GetManyIClaimsValidatorFromContainer(ctn di.Container) []IClaimsValidator

GetManyIClaimsValidatorFromContainer alternative to SafeGetManyIClaimsValidatorFromContainer but panics of object is not present

func SafeGetIClaimsValidatorFromContainer added in v0.1.298

func SafeGetIClaimsValidatorFromContainer(ctn di.Container) (IClaimsValidator, error)

SafeGetIClaimsValidatorFromContainer trys to get the object by type, will not panic, returns nil and error

func SafeGetManyIClaimsValidatorFromContainer added in v0.1.298

func SafeGetManyIClaimsValidatorFromContainer(ctn di.Container) ([]IClaimsValidator, error)

SafeGetManyIClaimsValidatorFromContainer trys to get the object by type, will not panic, returns nil and error

type IModularAuthMiddleware

type IModularAuthMiddleware interface {
	// GetUnaryServerInterceptor ...
	GetUnaryServerInterceptor() grpc.UnaryServerInterceptor
}

IModularAuthMiddleware ...

func GetIModularAuthMiddlewareFromContainer

func GetIModularAuthMiddlewareFromContainer(ctn di.Container) IModularAuthMiddleware

GetIModularAuthMiddlewareFromContainer alternative to SafeGetIModularAuthMiddlewareFromContainer but panics of object is not present

func GetManyIModularAuthMiddlewareFromContainer

func GetManyIModularAuthMiddlewareFromContainer(ctn di.Container) []IModularAuthMiddleware

GetManyIModularAuthMiddlewareFromContainer alternative to SafeGetManyIModularAuthMiddlewareFromContainer but panics of object is not present

func SafeGetIModularAuthMiddlewareFromContainer

func SafeGetIModularAuthMiddlewareFromContainer(ctn di.Container) (IModularAuthMiddleware, error)

SafeGetIModularAuthMiddlewareFromContainer trys to get the object by type, will not panic, returns nil and error

func SafeGetManyIModularAuthMiddlewareFromContainer

func SafeGetManyIModularAuthMiddlewareFromContainer(ctn di.Container) ([]IModularAuthMiddleware, error)

SafeGetManyIModularAuthMiddlewareFromContainer trys to get the object by type, will not panic, returns nil and error

type Operand added in v0.1.298

type Operand int

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL