acl

package
v0.0.0-...-d1cd67c Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2018 License: MIT Imports: 2 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ACLs must return this error if the peer is not authorized to take
	// an action.
	Unauthorized = fmt.Errorf("Client is Unauthorized to take that action")
)

Functions

This section is empty.

Types

type ACL

type ACL interface {
	// Check to see if action `string` is something that the the peer
	// `x509.Certificate` can preform. Additionally, the IP of the peer is
	// sent to the Authorize method through the final `string` argument.
	Authorize(string, *x509.Certificate, string) error
}

ACL Interface. This is used to let the CYBERCOM Server validate any incoming RPCs, and ensure the user is Authorized to take this action. The ACL need not validate identity (that's been established through x509 Certificate validation).

It's strongly advised that this "fail-closed", meaning, if the view, peer or client IP Address is not what is expected and known, it ought to return Unauthorized.

Jump to

Keyboard shortcuts

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