auth

package
v0.0.0-...-2e0ef96 Latest Latest
Warning

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

Go to latest
Published: May 10, 2020 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SubjectUnknown = iota
	SubjectEngineer
	SubjectSecAdmin
	SubjectOwner
	SubjectUDS
	SubjectAgent
)

Variables

This section is empty.

Functions

func CheckNodeDataAuthenticity

func CheckNodeDataAuthenticity(node *data.NodeDB, usersList []data.UserDB, verifyKey *data.ESAMPubKey) (bool, error)

func CheckSubjectAccessRights

func CheckSubjectAccessRights(authContext *Context, newObject interface{}, oldObject interface{}, reqType string) (bool, error)

func CheckUserDataAuthenticity

func CheckUserDataAuthenticity(user *data.UserDB, usersList []data.UserDB, verifyKey *data.ESAMPubKey) (bool, error)

Types

type Context

type Context struct {
	SubjectType int
	SubjectData interface{}
}

func IdentifySubject

func IdentifySubject(subjectESAMPubKey *data.ESAMPubKey, db *db.Desc) (*Context, error)

Jump to

Keyboard shortcuts

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