mirror of
git://git.9front.org/plan9front/plan9front
synced 2025-01-12 11:10:06 +00:00
Compare commits
7 commits
21731dd45e
...
68c89f4a43
Author | SHA1 | Date | |
---|---|---|---|
|
68c89f4a43 | ||
|
b849349e0c | ||
|
242e1dc552 | ||
|
ed318aac59 | ||
|
0bfa3ffcb4 | ||
|
d4938f099d | ||
|
e05e30eaca |
10 changed files with 116 additions and 65 deletions
|
@ -12,10 +12,7 @@ acid, truss, trump \- debugger
|
|||
.B -m
|
||||
.I machine
|
||||
] [
|
||||
.I pid
|
||||
]
|
||||
[
|
||||
.I textfile
|
||||
.I pid | textfile | pid textfile
|
||||
]
|
||||
.PP
|
||||
.B acid
|
||||
|
@ -27,10 +24,7 @@ acid, truss, trump \- debugger
|
|||
.B -l
|
||||
.B trump
|
||||
[
|
||||
.I pid
|
||||
]
|
||||
[
|
||||
.I textfile
|
||||
.I pid | textfile | pid textfile
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.I Acid
|
||||
|
@ -38,9 +32,9 @@ is a programmable symbolic debugger.
|
|||
It can inspect one or more processes that share an address space.
|
||||
A program to be debugged may be specified by the process id of
|
||||
a running or defunct process,
|
||||
or by the name of the program's text file
|
||||
.RB ( 8.out
|
||||
by default).
|
||||
or by the name of the program's text file. Both a pid and a file
|
||||
may be specified to supply debugging information for a process
|
||||
ran from a stripped binary.
|
||||
At the prompt,
|
||||
.I acid
|
||||
will store function definitions or print the value of expressions.
|
||||
|
|
57
sys/man/1/totp
Normal file
57
sys/man/1/totp
Normal file
|
@ -0,0 +1,57 @@
|
|||
.TH TOTP 1
|
||||
.SH NAME
|
||||
auth/userpasswd, auth/totp \- authentication agent
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
.B auth/userpasswd
|
||||
.I fmt
|
||||
.PP
|
||||
.B auth/totp
|
||||
[
|
||||
.B -k
|
||||
.I pattern
|
||||
] | [
|
||||
.B label
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
.I Totp
|
||||
queries and prints the
|
||||
.B RFC 6238
|
||||
TOTP code
|
||||
for the specified key tuple.
|
||||
The key tuple is selected using the provided label.
|
||||
This can be used to authenticate with services that require time based OTP.
|
||||
.PP
|
||||
.I Userpasswd
|
||||
queries and prints a cleartext user/password pair from factotum
|
||||
for the
|
||||
.B proto=pass
|
||||
key tuple specified in
|
||||
.IR fmt .
|
||||
This can be used by shell scripts to do cleartext password
|
||||
authentication.
|
||||
Using plain password authentication with factotum is discouraged,
|
||||
as it reveals the secrets in plain text.
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
Adding a TOTP key to factotum:
|
||||
.IP
|
||||
.EX
|
||||
% echo 'key label=mylabel secret=ABCDEF123456' \\
|
||||
> /mnt/factotum/ctl
|
||||
.EE
|
||||
.PP
|
||||
Generating a TOTP key from factotum:
|
||||
.IP
|
||||
.EX
|
||||
% auth/totp mylabel
|
||||
012345
|
||||
.EE
|
||||
.PP
|
||||
Retrieving a password from factotum:
|
||||
.IP
|
||||
.EX
|
||||
% auth/userpasswd 'server=setec service=ssh user=ori'
|
||||
toomanysecrets
|
||||
.EE
|
|
@ -8,37 +8,45 @@ vdiff \- a visual diff viewer
|
|||
]
|
||||
[
|
||||
.B -p
|
||||
.I strip
|
||||
.I nstrip
|
||||
]
|
||||
[
|
||||
.I file
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.I vdiff
|
||||
reads unified diff output from standard input and displays a colored version. Each file diff is displayed in a separate block that can be collapsed by a click on the file name. Right clicking on a line will send a
|
||||
reads unified diff output from
|
||||
.I file
|
||||
or standard input and displays a colored version.
|
||||
Each file within the diff is displayed in a separate block that can be collapsed by clicking on the file name.
|
||||
Right clicking on a line will send a
|
||||
.IR plumb (6)
|
||||
message to the
|
||||
.B edit
|
||||
port. Pressing
|
||||
port.
|
||||
Pressing
|
||||
.B q
|
||||
or
|
||||
.B del
|
||||
will exit
|
||||
.B vdiff.
|
||||
.I vdiff.
|
||||
.PP
|
||||
The
|
||||
.B \-b
|
||||
.B -b
|
||||
flag changes the color scheme to white text on a black background.
|
||||
.PP
|
||||
The
|
||||
.B \-p
|
||||
.I nstrip
|
||||
.B -p
|
||||
flag removes
|
||||
.I nstrip
|
||||
path elements from path before plumbing.
|
||||
path elements from the path before plumbing.
|
||||
.SH EXAMPLE
|
||||
.EX
|
||||
% git/diff | vdiff
|
||||
.EE
|
||||
.SH SOURCE
|
||||
/sys/src/cmd/vdiff.c
|
||||
.B /sys/src/cmd/vdiff.c
|
||||
.SH SEE ALSO
|
||||
.IR diff (1)
|
||||
.SH HISTORY
|
||||
vdiff first appeared in 9front (January, 2024).
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
.TH FACTOTUM 4
|
||||
.SH NAME
|
||||
factotum, fgui, userpasswd, totp \- authentication agent
|
||||
factotum, fgui \- authentication agent
|
||||
.SH SYNOPSIS
|
||||
.B auth/factotum
|
||||
[
|
||||
|
@ -23,17 +23,6 @@ factotum, fgui, userpasswd, totp \- authentication agent
|
|||
.B ...
|
||||
.PP
|
||||
.B auth/fgui
|
||||
.PP
|
||||
.B auth/userpasswd
|
||||
.I fmt
|
||||
.PP
|
||||
.B auth/totp
|
||||
[
|
||||
.B -k
|
||||
.I pattern
|
||||
] | [
|
||||
.B label
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.I Factotum
|
||||
is a user-level file system that
|
||||
|
@ -257,24 +246,6 @@ and
|
|||
For each requests, it unhides itself and waits for
|
||||
user input.
|
||||
See the sections on key confirmation and key prompting below.
|
||||
.PP
|
||||
.I Userpasswd
|
||||
queries and prints a cleartext user/password pair from factotum
|
||||
for the
|
||||
.B proto=pass
|
||||
key tuple specified in
|
||||
.IR fmt .
|
||||
This can be used by shell scripts to do cleartext password
|
||||
authentication.
|
||||
.PP
|
||||
.I Totp
|
||||
queries and prints an
|
||||
.B RFC 6238
|
||||
TOTP code
|
||||
for the
|
||||
.B proto=totp
|
||||
key tuple specified.
|
||||
This can be used to authenticate with services that require time based OTP.
|
||||
.SS "Key Tuples
|
||||
.PP
|
||||
A
|
||||
|
|
|
@ -89,6 +89,7 @@ places windows but does not mediate programs' access to the display device.
|
|||
Other files are unique to
|
||||
.IR rio .
|
||||
.TF window
|
||||
.PD
|
||||
.TP
|
||||
.B cons
|
||||
a virtual version of the standard terminal file from
|
||||
|
|
|
@ -1184,14 +1184,22 @@ rhubwrite(Ep *ep, void *a, long n)
|
|||
if(port > 0){
|
||||
dev->rhresetport = 0;
|
||||
|
||||
/* some controllers have to clear reset and set enable manually */
|
||||
/*
|
||||
* Some controllers have to clear reset and set enable manually.
|
||||
* We assume that clearing reset will transition the bus from
|
||||
* SE0 to idle state, and setting enable starts transmitting
|
||||
* SOF packets (keep alive).
|
||||
*
|
||||
* The delay between clearing reset and setting enable must
|
||||
* not exceed 3ms as this makes devices suspend themselfs.
|
||||
*/
|
||||
if(hp->portreset != nil){
|
||||
(*hp->portreset)(hp, port, 0);
|
||||
tsleep(&up->sleep, return0, nil, 50);
|
||||
tsleep(&up->sleep, return0, nil, 2);
|
||||
}
|
||||
if(hp->portenable != nil){
|
||||
(*hp->portenable)(hp, port, 1);
|
||||
tsleep(&up->sleep, return0, nil, 50);
|
||||
tsleep(&up->sleep, return0, nil, 2);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ void loadmoduleobjtype(void);
|
|||
void
|
||||
usage(void)
|
||||
{
|
||||
fprint(2, "usage: acid [-kqw] [-l library] [-m machine] [pid] [file]\n");
|
||||
fprint(2, "usage: acid [-kqw] [-l library] [-m machine] [pid | textfile | pid textfile]\n");
|
||||
exits("usage");
|
||||
}
|
||||
|
||||
|
@ -37,7 +37,7 @@ main(int argc, char *argv[])
|
|||
|
||||
argv0 = argv[0];
|
||||
pid = 0;
|
||||
aout = "8.out";
|
||||
aout = nil;
|
||||
quiet = 1;
|
||||
|
||||
mtype = 0;
|
||||
|
@ -81,6 +81,8 @@ main(int argc, char *argv[])
|
|||
}
|
||||
aout = argv[0];
|
||||
}
|
||||
} else {
|
||||
usage();
|
||||
}
|
||||
|
||||
fmtinstall('x', xfmt);
|
||||
|
|
|
@ -22,13 +22,11 @@ main(int argc, char **argv)
|
|||
if(argc != 1)
|
||||
usage();
|
||||
|
||||
quotefmtinstall();
|
||||
up = auth_getuserpasswd(auth_getkey, "proto=pass %s", argv[0]);
|
||||
if(up == nil) /* bug in factotum, fixed but need to reboot servers -rsc, 2/10/2002 */
|
||||
up = auth_getuserpasswd(nil, "proto=pass %s", argv[0]);
|
||||
if(up == nil)
|
||||
sysfatal("getuserpasswd: %r");
|
||||
|
||||
quotefmtinstall();
|
||||
print("%s\n%s\n", up->user, up->passwd);
|
||||
exits(0);
|
||||
exits(nil);
|
||||
}
|
||||
|
|
|
@ -2026,7 +2026,7 @@ readsnap(Fmsg *m, Fid *f, Fcall *r)
|
|||
}
|
||||
if(s->donescan){
|
||||
r->count = 0;
|
||||
return;
|
||||
goto Out;
|
||||
}
|
||||
p = r->data;
|
||||
n = m->count;
|
||||
|
@ -2037,7 +2037,7 @@ readsnap(Fmsg *m, Fid *f, Fcall *r)
|
|||
d.qid.path = UNPACK64(s->kv.v + 1);
|
||||
if((ns = dir2statbuf(&d, p, n)) == -1){
|
||||
r->count = 0;
|
||||
return;
|
||||
goto Out;
|
||||
}
|
||||
s->overflow = 0;
|
||||
p += ns;
|
||||
|
@ -2058,9 +2058,11 @@ readsnap(Fmsg *m, Fid *f, Fcall *r)
|
|||
n -= ns;
|
||||
}
|
||||
btexit(s);
|
||||
r->count = p - r->data;
|
||||
|
||||
Out:
|
||||
poperror();
|
||||
wunlock(f);
|
||||
r->count = p - r->data;
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -585,7 +585,7 @@ parse(int fd)
|
|||
void
|
||||
usage(void)
|
||||
{
|
||||
fprint(2, "%s [-b] [-p n]\n", argv0);
|
||||
fprint(2, "usage: %s [-b] [-p nstrip] [file]\n", argv0);
|
||||
exits("usage");
|
||||
}
|
||||
|
||||
|
@ -615,6 +615,16 @@ threadmain(int argc, char *argv[])
|
|||
usage();
|
||||
break;
|
||||
}ARGEND;
|
||||
switch(argc){
|
||||
default:
|
||||
usage();
|
||||
case 1:
|
||||
close(0);
|
||||
if(open(argv[0], OREAD) < 0)
|
||||
sysfatal("open: %r");
|
||||
case 0:
|
||||
break;
|
||||
}
|
||||
|
||||
parse(0);
|
||||
if(nblocks==1 && blocks[0]->nlines==0){
|
||||
|
|
Loading…
Reference in a new issue