Resolve typed credentials safely
This commit is contained in:
@@ -211,11 +211,18 @@ func buildDefaultAuditaRunner(cfg *config.Config) (audita.Runner, error) {
|
||||
if a.Report != nil {
|
||||
report = *a.Report
|
||||
}
|
||||
llmAPIKey := ""
|
||||
llmAPIKeyReference := ""
|
||||
if a.LLMAPIKey != nil {
|
||||
llmAPIKey = a.LLMAPIKey.Value()
|
||||
llmAPIKeyReference = a.LLMAPIKey.EnvName()
|
||||
}
|
||||
|
||||
runner, err := audita.NewSubprocessRunnerFromConfigValues(
|
||||
a.Binary,
|
||||
a.Timeout,
|
||||
a.LLMAPIKeyEnv,
|
||||
llmAPIKey,
|
||||
llmAPIKeyReference,
|
||||
append([]string(nil), a.Modules...),
|
||||
a.BaseURL,
|
||||
a.Model,
|
||||
|
||||
Reference in New Issue
Block a user