summaryrefslogtreecommitdiff
path: root/sys/src/cmd/cwfs/con.c
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2022-12-18 13:45:31 +0000
committercinap_lenrek <cinap_lenrek@felloff.net>2022-12-18 13:45:31 +0000
commite0372c26e9263207fb9ede2b8d706e4f8cd24b7a (patch)
tree011914beff271ee531f792d669ec63d97ccdcf55 /sys/src/cmd/cwfs/con.c
parent0f0270cdd612d6bc7f065b5c25c4cfffc2c0bd87 (diff)
cwfs: remove noauth and nonone commans from fileserver console
The noauth and nonone commands are only valid in config mode. The problem is that some people assumed that issuing the noauth command in the runtime fileserver console would be persistent across reboots, which is not the case. To avoid this confusion, we remove these commands from the fileserver console. To still give a way to disable authentication at runtime, define a authdisabled flag that can be toggled at runtime.
Diffstat (limited to 'sys/src/cmd/cwfs/con.c')
-rw-r--r--sys/src/cmd/cwfs/con.c17
1 files changed, 1 insertions, 16 deletions
diff --git a/sys/src/cmd/cwfs/con.c b/sys/src/cmd/cwfs/con.c
index 1d2e0c608..ed76c9703 100644
--- a/sys/src/cmd/cwfs/con.c
+++ b/sys/src/cmd/cwfs/con.c
@@ -730,20 +730,6 @@ cmd_time(int argc, char *argv[])
}
void
-cmd_noauth(int, char *[])
-{
- noauth = !noauth;
- print("auth %s\n", noauth ? "disabled" : "enabled");
-}
-
-void
-cmd_nonone(int, char *[])
-{
- nonone = !nonone;
- print("none %s\n", nonone ? "disabled" : "enabled");
-}
-
-void
cmd_noattach(int, char *[])
{
noattach = !noattach;
@@ -816,8 +802,6 @@ installcmds(void)
cmd_install("who", "[user ...] -- print attaches", cmd_who);
cmd_install("hangup", "chan -- clunk files", cmd_hangup);
cmd_install("printconf", "-- print configuration", cmd_printconf);
- cmd_install("noauth", "-- toggle noauth flag", cmd_noauth);
- cmd_install("nonone", "-- toggle nonone flag", cmd_nonone);
cmd_install("noattach", "-- toggle noattach flag", cmd_noattach);
cmd_install("files", "-- report on files structure", cmd_files);
@@ -825,6 +809,7 @@ installcmds(void)
errorflag = flag_install("error", "-- on errors");
whoflag = flag_install("allchans", "-- on who");
authdebugflag = flag_install("authdebug", "-- report authentications");
+ authdisableflag = flag_install("authdisable", "-- disable authentication");
}
int