Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkg/awmg/gateway.go
Original file line number Diff line number Diff line change
Expand Up @@ -440,8 +440,8 @@ func rewriteMCPConfigForGateway(configPath string, config *MCPGatewayServiceConf
gatewayLog.Printf("Writing %d bytes to config file", len(data))
fmt.Fprintln(os.Stderr, console.FormatInfoMessage(fmt.Sprintf("Writing %d bytes to config file", len(data))))

// Write back to file
if err := os.WriteFile(configPath, data, 0644); err != nil {
// Write back to file with restricted permissions (0600) since it contains sensitive API keys
if err := os.WriteFile(configPath, data, 0600); err != nil {
gatewayLog.Printf("Failed to write rewritten config: %v", err)
fmt.Fprintln(os.Stderr, console.FormatErrorMessage(fmt.Sprintf("Failed to write rewritten config: %v", err)))
return fmt.Errorf("failed to write rewritten config: %w", err)
Expand Down