aboutsummaryrefslogtreecommitdiffstats
path: root/sym.go
diff options
context:
space:
mode:
Diffstat (limited to 'sym.go')
-rw-r--r--sym.go13
1 files changed, 11 insertions, 2 deletions
diff --git a/sym.go b/sym.go
index 2405feb..e9eef94 100644
--- a/sym.go
+++ b/sym.go
@@ -15,9 +15,18 @@ type subcommand interface {
func whichSubcommand(name string) (subcommand, bool) {
switch filepath.Base(name) {
case "enc":
- return &defaultEncryptOptions, true
+ return &encryptOptions{
+ passwordIn: termReadPassword,
+ passwordOut: os.Stderr,
+ stdin: os.Stdin,
+ stdout: os.Stdout,
+ }, true
case "dec":
- return &defaultDecryptOptions, true
+ return &decryptOptions{
+ passwordIn: termReadPassword,
+ stdin: os.Stdin,
+ stdout: os.Stdout,
+ }, true
default:
return nil, false
}