@ -251,7 +251,7 @@ func validateConfig(s config.Config) error {
}
}
{
kmsCfg , err := crypto . LookupConfig ( s , globalCertsCADir . Get ( ) , NewCustom HTTPTransport ( ) )
kmsCfg , err := crypto . LookupConfig ( s , globalCertsCADir . Get ( ) , NewGateway HTTPTransport ( ) )
if err != nil {
return err
}
@ -269,7 +269,7 @@ func validateConfig(s config.Config) error {
}
if _ , err := openid . LookupConfig ( s [ config . IdentityOpenIDSubSys ] [ config . Default ] ,
NewCustom HTTPTransport ( ) , xhttp . DrainBody ) ; err != nil {
NewGateway HTTPTransport ( ) , xhttp . DrainBody ) ; err != nil {
return err
}
@ -279,7 +279,7 @@ func validateConfig(s config.Config) error {
}
if _ , err := opa . LookupConfig ( s [ config . PolicyOPASubSys ] [ config . Default ] ,
NewCustom HTTPTransport ( ) , xhttp . DrainBody ) ; err != nil {
NewGateway HTTPTransport ( ) , xhttp . DrainBody ) ; err != nil {
return err
}
@ -287,7 +287,7 @@ func validateConfig(s config.Config) error {
return err
}
return notify . TestNotificationTargets ( s , GlobalServiceDoneCh , NewCustom HTTPTransport ( ) ,
return notify . TestNotificationTargets ( s , GlobalServiceDoneCh , NewGateway HTTPTransport ( ) ,
globalNotificationSys . ConfiguredTargetIDs ( ) )
}
@ -362,7 +362,7 @@ func lookupConfigs(s config.Config) {
}
}
kmsCfg , err := crypto . LookupConfig ( s , globalCertsCADir . Get ( ) , NewCustom HTTPTransport ( ) )
kmsCfg , err := crypto . LookupConfig ( s , globalCertsCADir . Get ( ) , NewGateway HTTPTransport ( ) )
if err != nil {
logger . LogIf ( ctx , fmt . Errorf ( "Unable to setup KMS config: %w" , err ) )
}
@ -381,13 +381,13 @@ func lookupConfigs(s config.Config) {
}
globalOpenIDConfig , err = openid . LookupConfig ( s [ config . IdentityOpenIDSubSys ] [ config . Default ] ,
NewCustom HTTPTransport ( ) , xhttp . DrainBody )
NewGateway HTTPTransport ( ) , xhttp . DrainBody )
if err != nil {
logger . LogIf ( ctx , fmt . Errorf ( "Unable to initialize OpenID: %w" , err ) )
}
opaCfg , err := opa . LookupConfig ( s [ config . PolicyOPASubSys ] [ config . Default ] ,
NewCustom HTTPTransport ( ) , xhttp . DrainBody )
NewGateway HTTPTransport ( ) , xhttp . DrainBody )
if err != nil {
logger . LogIf ( ctx , fmt . Errorf ( "Unable to initialize OPA: %w" , err ) )
}
@ -412,22 +412,23 @@ func lookupConfigs(s config.Config) {
for _ , l := range loggerCfg . HTTP {
if l . Enabled {
// Enable http logging
logger . AddTarget ( http . New ( l . Endpoint , loggerUserAgent , string ( logger . All ) , NewCustom HTTPTransport ( ) ) )
logger . AddTarget ( http . New ( l . Endpoint , loggerUserAgent , string ( logger . All ) , NewGateway HTTPTransport ( ) ) )
}
}
for _ , l := range loggerCfg . Audit {
if l . Enabled {
// Enable http audit logging
logger . AddAuditTarget ( http . New ( l . Endpoint , loggerUserAgent , string ( logger . All ) , NewCustom HTTPTransport ( ) ) )
logger . AddAuditTarget ( http . New ( l . Endpoint , loggerUserAgent , string ( logger . All ) , NewGateway HTTPTransport ( ) ) )
}
}
globalConfigTargetList , err = notify . GetNotificationTargets ( s , GlobalServiceDoneCh , NewCustom HTTPTransport ( ) )
globalConfigTargetList , err = notify . GetNotificationTargets ( s , GlobalServiceDoneCh , NewGateway HTTPTransport ( ) )
if err != nil {
logger . LogIf ( ctx , fmt . Errorf ( "Unable to initialize notification target(s): %w" , err ) )
}
globalEnvTargetList , err = notify . GetNotificationTargets ( newServerConfig ( ) , GlobalServiceDoneCh , NewCustomHTTPTransport ( ) )
globalEnvTargetList , err = notify . GetNotificationTargets ( newServerConfig ( ) , GlobalServiceDoneCh , NewGatewayHTTPTransport ( ) )
if err != nil {
logger . LogIf ( ctx , fmt . Errorf ( "Unable to initialize notification target(s): %w" , err ) )
}