nfsense/internal/api/firewall/source_nat_rules.go
2023-04-01 18:17:48 +02:00

17 lines
402 B
Go

package firewall
import (
"context"
"nfsense.net/nfsense/internal/definitions"
)
type GetSourceNATRulesResult struct {
SourceNATRules []definitions.SourceNATRule
}
func (f *Firewall) GetSourceNATRules(ctx context.Context, params struct{}) (GetSourceNATRulesResult, error) {
return GetSourceNATRulesResult{
SourceNATRules: f.ConfigManager.GetPendingConfig().Firewall.SourceNATRules,
}, nil
}