Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertPolicy ¶
AssertPolicy ensures that a policy exists that matches our expectations.
func NewSslPolicy ¶
func NewSslPolicy(name, profile, version string) compute.SslPolicy
NewSslPolicy returns instance of the configuration options necessary to create our globally enforced SSL Policy.
func SelectProxies ¶
func SelectProxies(proxies *compute.TargetHttpsProxyList, blacklist map[string]struct{}) *compute.TargetHttpsProxyList
SelectProxies removes black listed proxies from our list of targets.
Types ¶
type Config ¶
type Config struct {
IgnoreProxies map[string]struct{}
}
Config contains the configuration values that the rest of the program will leverage. Fields from the YAML are manipulated to become more convenient for the internal program.
func LoadConfig ¶
LoadConfig returns an instance of the unmarshalled configuration file.
func (*Config) PolicyName ¶
PolicyName will be used by the service to fetch the current TLS Policy by this name and if not found will create it. The Version string at the end is very important! It will be used to upgrade TLS policies in the future.
func (*Config) Project ¶
Project returns the ID (not the display name) of the Google Cloud Project to work under.
func (*Config) SslProfile ¶
SslProfile returns the string value of pre-configured profile defined by GCP. The acceptable value MUST BE either `COMPATIBLE`/`MODERN`/`RESTRICTED`. Default is "MODERN"
func (*Config) TlsVersion ¶
TlsVersion will be used current TLS Policy by this value. The acceptable value MUST BE either`TLS_1_1`/`TLS_1_2`/`TLS_1_3` Default is "TLS_1_2"