chiark
/
gitweb
/
~mdw
/
chopwood
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
c81f819
)
service.py: Fix commentary, and default remote command.
author
Mark Wooding
<mdw@distorted.org.uk>
Mon, 22 Dec 2014 20:32:58 +0000
(20:32 +0000)
committer
Mark Wooding
<mdw@distorted.org.uk>
Sat, 4 Apr 2015 14:25:55 +0000
(15:25 +0100)
service.py
patch
|
blob
|
blame
|
history
diff --git
a/service.py
b/service.py
index ddd28b9a121cadd76617cdc39ddefb460d42fce7..786ab92debe05526ef09178059ccd74212a6bcdb 100644
(file)
--- a/
service.py
+++ b/
service.py
@@
-284,6
+284,14
@@
class SSHRemoteService (BasicRemoteService):
`clear SERVICE USER'
Clear the USER's password for SERVICE.
`clear SERVICE USER'
Clear the USER's password for SERVICE.
+ `mkpwent USER SERVICE [FIELDS ...]'
+ Install a record for USER in the SERVICE, supplying any other
+ necessary FIELDS in the appropriate format. The user's password is
+ provided on the next line of standard input.
+
+ `rmpwent USER SERVICE'
+ Remove USER's password record for SERVICE.
+
Arguments are form-url-encoded, since SSH doesn't preserve token boundaries
in its argument list.
Arguments are form-url-encoded, since SSH doesn't preserve token boundaries
in its argument list.
@@
-352,14
+360,15
@@
class CommandRemoteService (BasicRemoteService):
commands, then your easy approach is to set commands for the operations you
can handle in the OPMAP, and set the DEFAULT to something like
commands, then your easy approach is to set commands for the operations you
can handle in the OPMAP, and set the DEFAULT to something like
- ['echo', 'ERR
500', 'unsupported command:']
+ ['echo', 'ERR
', '
500', 'unsupported command:']
to reject other commands.
"""
R_PAT = RX.compile('%(.)')
to reject other commands.
"""
R_PAT = RX.compile('%(.)')
- def __init__(me, default = ['ERR', '500', 'unimplemented command:'],
+ def __init__(me,
+ default = ['echo', 'ERR', '500', 'unimplemented command:'],
opmap = {}, *args, **kw):
"""Initialize the command remote service."""
super(CommandRemoteService, me).__init__(*args, **kw)
opmap = {}, *args, **kw):
"""Initialize the command remote service."""
super(CommandRemoteService, me).__init__(*args, **kw)