X-Git-Url: https://ruderich.org/simon/gitweb/?a=blobdiff_plain;f=config.go;h=8db49c1fe4875ebd959a084996280ea6f82cef09;hb=526f6f1db39bde8ca1f7684225a3983634bddafe;hp=8e9a6308124a4d74adb7f8e2dde1ad82f16b84bf;hpb=92afde4e875a96e1ab865e29b9f0d11b08d7db1c;p=nsscash%2Fnsscash.git diff --git a/config.go b/config.go index 8e9a630..8db49c1 100644 --- a/config.go +++ b/config.go @@ -32,6 +32,7 @@ type File struct { Type FileType Url string Path string + CA string body []byte // internally used by handleFiles() } @@ -42,6 +43,7 @@ type FileType int const ( FileTypePlain FileType = iota FileTypePasswd + FileTypeGroup ) func (t *FileType) UnmarshalText(text []byte) error { @@ -50,6 +52,8 @@ func (t *FileType) UnmarshalText(text []byte) error { *t = FileTypePlain case "passwd": *t = FileTypePasswd + case "group": + *t = FileTypeGroup default: return fmt.Errorf("invalid file type %q", text) }