Documentation ¶
Index ¶
- Variables
- func GetInt64FromClaims(claims *map[string]interface{}, key string) int64
- func GetStringFromClaims(claims *map[string]interface{}, key string) string
- type SafeAuth
- func (s *SafeAuth) AddSharedSecret(ctx context.Context, req *pb.AddSharedSecretRequest) (*pb.AddSharedSecretResponse, error)
- func (s *SafeAuth) ClearSharedSecrets(ctx context.Context, req *pb.ClearSharedSecretsRequest) (*pb.ClearSharedSecretsResponse, error)
- func (s *SafeAuth) CopyKeyNode(ctx context.Context, req *pb.CopyKeyNodeRequest) (*pb.CopyKeyNodeResponse, error)
- func (s *SafeAuth) CreateDataKey(ctx context.Context, req *pb.CreateDataKeyRequest) (*pb.CreateDataKeyResponse, error)
- func (s *SafeAuth) CreateKeyNode(ctx context.Context, req *pb.CreateKeyNodeRequest) (*pb.CreateKeyNodeResponse, error)
- func (s *SafeAuth) DeleteDataKey(ctx context.Context, req *pb.DeleteDataKeyRequest) (*pb.DeleteDataKeyResponse, error)
- func (s *SafeAuth) DeleteKeyNode(ctx context.Context, req *pb.DeleteKeyNodeRequest) (*pb.DeleteKeyNodeResponse, error)
- func (s *SafeAuth) DisableKeyNode(ctx context.Context, req *pb.DisableKeyNodeRequest) (*pb.DisableKeyNodeResponse, error)
- func (s *SafeAuth) EnableKeyNode(ctx context.Context, req *pb.EnableKeyNodeRequest) (*pb.EnableKeyNodeResponse, error)
- func (s *SafeAuth) GetDataKey(ctx context.Context, req *pb.GetDataKeyRequest) (*pb.GetDataKeyResponse, error)
- func (s *SafeAuth) GetDataKeyById(ctx context.Context, req *pb.GetDataKeyByIdRequest) (*pb.GetDataKeyByIdResponse, error)
- func (s *SafeAuth) GetDataKeysByAccount(ctx context.Context, req *pb.GetDataKeysByAccountRequest) (*pb.GetDataKeysByAccountResponse, error)
- func (s *SafeAuth) GetDecryptedDataKey(ctx context.Context, req *pb.GetDecryptedDataKeyRequest) (*pb.GetDecryptedDataKeyResponse, error)
- func (s *SafeAuth) GetDecryptedKeyNode(ctx context.Context, req *pb.GetDecryptedKeyNodeRequest) (*pb.GetDecryptedKeyNodeResponse, error)
- func (s *SafeAuth) GetJwtFromContext(ctx context.Context) (*map[string]interface{}, error)
- func (s *SafeAuth) GetKeyNode(ctx context.Context, req *pb.GetKeyNodeRequest) (*pb.GetKeyNodeResponse, error)
- func (s *SafeAuth) GetKeyNodeById(ctx context.Context, req *pb.GetKeyNodeByIdRequest) (*pb.GetKeyNodeByIdResponse, error)
- func (s *SafeAuth) GetKeyNodeByPath(ctx context.Context, req *pb.GetKeyNodeByPathRequest) (*pb.GetKeyNodeByPathResponse, error)
- func (s *SafeAuth) GetServerVersion(ctx context.Context, req *pb.GetServerVersionRequest) (*pb.GetServerVersionResponse, error)
- func (s *SafeAuth) NewApiServer(gServer *grpc.Server) error
- func (s *SafeAuth) ReEncryptKeyNode(ctx context.Context, req *pb.ReEncryptKeyNodeRequest) (*pb.ReEncryptKeyNodeResponse, error)
- func (s *SafeAuth) SetDatabaseConnection(sqlDB *sql.DB)
- func (s *SafeAuth) SetLogger(logger log.Logger)
- func (s *SafeAuth) SetPublicKey(publicKeyFile string) error
Constants ¶
This section is empty.
Variables ¶
View Source
var NotImplemented = errors.New("not implemented")
Functions ¶
func GetInt64FromClaims ¶
func GetStringFromClaims ¶
Types ¶
type SafeAuth ¶ added in v0.9.2
type SafeAuth struct {
// contains filtered or unexported fields
}
func NewSafeboxAuth ¶
func NewSafeboxAuth(safeService pb.MServiceSafeboxServer) *SafeAuth
func (*SafeAuth) AddSharedSecret ¶ added in v0.9.2
func (s *SafeAuth) AddSharedSecret(ctx context.Context, req *pb.AddSharedSecretRequest) (*pb.AddSharedSecretResponse, error)
initialize service with shared secret
func (*SafeAuth) ClearSharedSecrets ¶ added in v0.9.2
func (s *SafeAuth) ClearSharedSecrets(ctx context.Context, req *pb.ClearSharedSecretsRequest) (*pb.ClearSharedSecretsResponse, error)
remocve shared secrets
func (*SafeAuth) CopyKeyNode ¶ added in v0.9.2
func (s *SafeAuth) CopyKeyNode(ctx context.Context, req *pb.CopyKeyNodeRequest) (*pb.CopyKeyNodeResponse, error)
copy a key node to new path
func (*SafeAuth) CreateDataKey ¶ added in v0.9.2
func (s *SafeAuth) CreateDataKey(ctx context.Context, req *pb.CreateDataKeyRequest) (*pb.CreateDataKeyResponse, error)
create a new data key
func (*SafeAuth) CreateKeyNode ¶ added in v0.9.2
func (s *SafeAuth) CreateKeyNode(ctx context.Context, req *pb.CreateKeyNodeRequest) (*pb.CreateKeyNodeResponse, error)
create a new key node, encrypting value creating tree node if necessary
func (*SafeAuth) DeleteDataKey ¶ added in v0.9.2
func (s *SafeAuth) DeleteDataKey(ctx context.Context, req *pb.DeleteDataKeyRequest) (*pb.DeleteDataKeyResponse, error)
delete a data key
func (*SafeAuth) DeleteKeyNode ¶ added in v0.9.2
func (s *SafeAuth) DeleteKeyNode(ctx context.Context, req *pb.DeleteKeyNodeRequest) (*pb.DeleteKeyNodeResponse, error)
delete a key node
func (*SafeAuth) DisableKeyNode ¶ added in v0.9.2
func (s *SafeAuth) DisableKeyNode(ctx context.Context, req *pb.DisableKeyNodeRequest) (*pb.DisableKeyNodeResponse, error)
disable a key node
func (*SafeAuth) EnableKeyNode ¶ added in v0.9.2
func (s *SafeAuth) EnableKeyNode(ctx context.Context, req *pb.EnableKeyNodeRequest) (*pb.EnableKeyNodeResponse, error)
enable a key node
func (*SafeAuth) GetDataKey ¶ added in v0.9.2
func (s *SafeAuth) GetDataKey(ctx context.Context, req *pb.GetDataKeyRequest) (*pb.GetDataKeyResponse, error)
get a data key
func (*SafeAuth) GetDataKeyById ¶ added in v0.9.2
func (s *SafeAuth) GetDataKeyById(ctx context.Context, req *pb.GetDataKeyByIdRequest) (*pb.GetDataKeyByIdResponse, error)
get a data key by id
func (*SafeAuth) GetDataKeysByAccount ¶ added in v0.9.2
func (s *SafeAuth) GetDataKeysByAccount(ctx context.Context, req *pb.GetDataKeysByAccountRequest) (*pb.GetDataKeysByAccountResponse, error)
get a data keys by account_name
func (*SafeAuth) GetDecryptedDataKey ¶ added in v0.9.2
func (s *SafeAuth) GetDecryptedDataKey(ctx context.Context, req *pb.GetDecryptedDataKeyRequest) (*pb.GetDecryptedDataKeyResponse, error)
get a decrypted version of data key
func (*SafeAuth) GetDecryptedKeyNode ¶ added in v0.9.2
func (s *SafeAuth) GetDecryptedKeyNode(ctx context.Context, req *pb.GetDecryptedKeyNodeRequest) (*pb.GetDecryptedKeyNodeResponse, error)
get a decrypted version of key node
func (*SafeAuth) GetJwtFromContext ¶ added in v0.9.2
func (*SafeAuth) GetKeyNode ¶ added in v0.9.2
func (s *SafeAuth) GetKeyNode(ctx context.Context, req *pb.GetKeyNodeRequest) (*pb.GetKeyNodeResponse, error)
get a key node by node and path
func (*SafeAuth) GetKeyNodeById ¶ added in v0.9.2
func (s *SafeAuth) GetKeyNodeById(ctx context.Context, req *pb.GetKeyNodeByIdRequest) (*pb.GetKeyNodeByIdResponse, error)
get a key node by id
func (*SafeAuth) GetKeyNodeByPath ¶ added in v0.9.2
func (s *SafeAuth) GetKeyNodeByPath(ctx context.Context, req *pb.GetKeyNodeByPathRequest) (*pb.GetKeyNodeByPathResponse, error)
get a list of key nodes by path
func (*SafeAuth) GetServerVersion ¶ added in v0.9.2
func (s *SafeAuth) GetServerVersion(ctx context.Context, req *pb.GetServerVersionRequest) (*pb.GetServerVersionResponse, error)
get current server version and uptime - health check
func (*SafeAuth) NewApiServer ¶ added in v0.9.2
func (*SafeAuth) ReEncryptKeyNode ¶ added in v0.9.2
func (s *SafeAuth) ReEncryptKeyNode(ctx context.Context, req *pb.ReEncryptKeyNodeRequest) (*pb.ReEncryptKeyNodeResponse, error)
re-encrypt a key node
func (*SafeAuth) SetDatabaseConnection ¶ added in v0.9.2
func (*SafeAuth) SetPublicKey ¶ added in v0.9.2
Click to show internal directories.
Click to hide internal directories.