Documentation

Overview

    Package gitacls implements read ACLs for Git/Gerrit data.

    Index

    Constants

    This section is empty.

    Variables

    This section is empty.

    Functions

    func ValidateConfig

    func ValidateConfig(ctx *validation.Context, cfg []*config.Settings_SourceAcls)

      ValidateConfig passes all validation errors through validation context.

      Types

      type ACLs

      type ACLs struct {
      	// contains filtered or unexported fields
      }

        ACLs define readers for git repositories and Gerrits CLs.

        func FromConfig

        func FromConfig(c context.Context, cfg []*config.Settings_SourceAcls) (*ACLs, error)

          FromConfig returns ACLs if config is valid.

          func (*ACLs) IsAllowed

          func (a *ACLs) IsAllowed(c context.Context, host, project string) (bool, error)

            IsAllowed returns whether current identity has been granted read access to given Git/Gerrit project.

            Source Files