{"record":{"id":"2ab2fc639ba00a72","repo":"kgretzky/evilginx2","slug":"phishlet-s-is-a-template-you-have-to-create-2ab2fc","errorCode":null,"errorMessage":"phishlet '%s' is a template - you have to 'create' child phishlet from it, with predefined parameters, before you can enable it.","messagePattern":"phishlet '(.+?)' is a template - you have to 'create' child phishlet from it, with predefined parameters, before you can enable it\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"core/terminal.go","lineNumber":630,"sourceCode":"\t} else if pn == 2 {\n\t\tswitch args[0] {\n\t\tcase \"delete\":\n\t\t\terr := t.cfg.DeleteSubPhishlet(args[1])\n\t\t\tif err != nil {\n\t\t\t\tlog.Error(\"%v\", err)\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\tt.cfg.SaveSubPhishlets()\n\t\t\tlog.Info(\"deleted child phishlet: %s\", args[1])\n\t\t\treturn nil\n\t\tcase \"enable\":\n\t\t\tpl, err := t.cfg.GetPhishlet(args[1])\n\t\t\tif err != nil {\n\t\t\t\tlog.Error(\"%v\", err)\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif pl.isTemplate {\n\t\t\t\treturn fmt.Errorf(\"phishlet '%s' is a template - you have to 'create' child phishlet from it, with predefined parameters, before you can enable it.\", args[1])\n\t\t\t}\n\t\t\terr = t.cfg.SetSiteEnabled(args[1])\n\t\t\tif err != nil {\n\t\t\t\tt.cfg.SetSiteDisabled(args[1])\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tt.manageCertificates(true)\n\t\t\treturn nil\n\t\tcase \"disable\":\n\t\t\terr := t.cfg.SetSiteDisabled(args[1])\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tt.manageCertificates(false)\n\t\t\treturn nil\n\t\tcase \"hide\":\n\t\t\terr := t.cfg.SetSiteHidden(args[1], true)\n\t\t\tif err != nil {","sourceCodeStart":612,"sourceCodeEnd":648,"githubUrl":"https://github.com/kgretzky/evilginx2/blob/4c0988a1d9db4d172a185e979a38bfd0efdb5830/core/terminal.go#L612-L648","documentation":"Template phishlets are blueprints and cannot be enabled directly. Before `phishlets enable <name>`, you must create a child phishlet via `phishlets create <template> <child> param=value...` which bakes in the required custom parameters, then enable the child.","triggerScenarios":"Running `phishlets enable <name>` where args[1] resolves via GetPhishlet to a phishlet with isTemplate=true (a base/template phishlet, not a created child).","commonSituations":"User enabled a freshly downloaded template phishlet without instantiating it; old workflows from versions without template phishlets; ambiguous phishlet name matched the template instead of the child.","solutions":["Create a child first: `phishlets create <template> <child> param1=value1 ...`","Then enable the child: `phishlets enable <template>:<child>`","Use the fully qualified child name (parent:child) if names are ambiguous","List phishlets to confirm which entries are templates vs children"],"exampleFix":"// before\nphishlets enable o365\n// after\nphishlets create o365 corp domain=corp.example.com\nphishlets enable o365:corp","handlingStrategy":"validation","validationCode":"pl, err := t.cfg.GetPhishlet(name)\nif err == nil && pl.IsTemplate {\n    return fmt.Errorf(\"%s is a template; run: phishlets create %s <child> key=value first\", name, name)\n}","typeGuard":"func isTemplatePhishlet(pl *Phishlet) bool { return pl != nil && pl.IsTemplate }","tryCatchPattern":"if err := enablePhishlet(name); err != nil {\n    if strings.Contains(err.Error(), \"is a template\") {\n        // fall back to creating a child phishlet\n        createChildFromTemplate(name)\n    }\n}","preventionTips":["Never call enable directly on template phishlets","Instantiate children with create first, then enable the parent:child name","List phishlets to distinguish templates from children"],"tags":["phishlet","configuration","workflow"],"backgroundTag":"phishlet-template-not-instantiated","analyzedSha":"4c0988a1d9db4d172a185e979a38bfd0efdb5830","analyzedAt":"2026-09-05T19:23:07.238Z","contentChangedAt":"2026-09-05T19:23:07.238Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}