]> ruderich.org/simon Gitweb - nsscash/nsscash.git/blobdiff - config.go
nsscash: add "ca" option for files
[nsscash/nsscash.git] / config.go
index 8e9a6308124a4d74adb7f8e2dde1ad82f16b84bf..8db49c1fe4875ebd959a084996280ea6f82cef09 100644 (file)
--- 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)
        }