David Howells [Wed, 7 Feb 2018 06:55:16 +0000 (06:55 +0000)]
Add VOLSER.GetSize and uint64_t xdr support
Add the VOLSER.GetSize RPC operation and add the uint64_t encode/decode
support to rxgen.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 12 Feb 2018 22:13:56 +0000 (22:13 +0000)]
aklog now makes key name lower case
When aklog adds a key, it now makes the cell name lower case, so kafs-utils
needs to follow suit.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 12 Feb 2018 23:07:39 +0000 (23:07 +0000)]
Fix -noauth security handling
Fix the handling of -noauth security in the af_rxrpc transport module.
Without this, a SEGV can be triggered by:
pts examine -nameorid dhowells -noauth -cell my.cell.org
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 25 Sep 2015 22:21:50 +0000 (23:21 +0100)]
Dynamically load the transport interface as a shared library
Make it possible to change the transport interface by abstracting it out
into a shared library and loading it dynamically by name.
kafs/main.py currently loads it by specific name:
rpc.load_kafs_transport("/usr/local/lib64/kafs_af_rxrpc.so")
but this needs altering so that the name of the transport can be supplied
by the user.
File kafs/transport.h defines the interface as a table of function pointers
defined as:
struct kafs_transport kafs_transport = {
.id = kafs_transport_id,
.name = "<name of transport>"
...
};
The ->new_service(), ->shutdown_service() and ->accept_call() methods
aren't currently used. Each transport interface can define the following
structures in any way it sees fit:
struct kafs_transport_handle;
struct kafs_security_handle;
struct kafs_connection_handle;
struct kafs_service_handle;
struct kafs_call_handle;
As far as kafs-utils is concerned they're opaque handles.
Note that the interface is expected to invoke the data_ready_func function
passed to ->make_call() when data becomes available. At that point, the
data_ready_func function will call ->recv_data() to load data into the
supplied buffers. ->poll_connection() is called to see if there's any data
and potentially to wait for it if there isn't.
The AF_RXRPC transport interface is now separated from core kafs-utils code
and is currently not built or installed by the setup.py script. This will
need fixing in some manner.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 3 Mar 2017 15:37:30 +0000 (15:37 +0000)]
The bash-comp-helper.py script is now in kafs/, not suite/
The bash-comp-helper.py script is now in kafs/, not suite/ so bash_complete
needs to change to reflect that.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 3 Mar 2017 15:00:34 +0000 (15:00 +0000)]
Fix calculation of padding in the enc/dec routines
Fix calculation of that amount of padding around a blob or string in the
encoding and decoding routines.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 2 Mar 2017 10:00:22 +0000 (10:00 +0000)]
Fix warnings from -Wsign-compare
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 2 Mar 2017 09:37:35 +0000 (09:37 +0000)]
Add more stuff to "make clean"
Get "make clean" to delete some stuff left behind by python.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 2 Mar 2017 09:31:43 +0000 (09:31 +0000)]
Add a TODO list
Add a TODO list, including the commands that need implementing.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 23 Sep 2015 11:39:18 +0000 (12:39 +0100)]
setup: Clean up some print statements
Clean up some debugging print statements from the setup script.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 23 Sep 2015 10:41:44 +0000 (11:41 +0100)]
setup: Sort out the Python setup so that it can build an RPM
This does the following steps:
(1) Adds a new command class to handle rxgen in the setup script so that the
Python builder runs the XDR routine generation rather than needing a
separate make step.
(2) Moves everything that needs installing under kafs - which will be the
name of the module.
(3) Renames the module produced by the various C components to kafs.rpc and
accesses it from python scripts with "import kafs.rpc as rpc" and then
uses "rpc." instead of "kafs." to qualify accesses to the module.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 22 Sep 2015 16:38:42 +0000 (17:38 +0100)]
Remove the Perl rxgen
Remove the Perl rxgen program as it is now replaced with the Python
version.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 4 Sep 2015 10:22:01 +0000 (11:22 +0100)]
Rewrite rxgen in python using the ply module
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sun, 20 Sep 2015 21:53:18 +0000 (22:53 +0100)]
Convert the xg files to UTF-8 to keep Python happy
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 2 Sep 2015 19:12:54 +0000 (20:12 +0100)]
Package setup script should be called setup.py
Package setup script should be called setup.py so call it that.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 17:47:49 +0000 (18:47 +0100)]
Implement "vos create"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 17:51:11 +0000 (18:51 +0100)]
The "vos examine" script needs to import AFSException to be able to use it
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 17:50:06 +0000 (18:50 +0100)]
Fix some places IP addresses are output as strings
Fix some places IP addresses are supposed to be output as strings but instead
try to output a non-string type.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 13:58:45 +0000 (14:58 +0100)]
Strip AFSVol prefixes from RPC call names in volumeserver.xg
Strip AFSVol prefixes from RPC call names in volumeserver.xg as they're
redundant given that the the xg compiler prefixes them with the package name.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 13:22:38 +0000 (14:22 +0100)]
"pts createuser" should use PR_NewEntry and not PR_INewEntry
"pts createuser" should use PR_NewEntry and not PR_INewEntry for two reasons:
firstly, the latter doesn't return the expected new database entry ID, and
secondly, the latter fails with PRPERM when the former works.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 13:27:06 +0000 (14:27 +0100)]
Fix callers of the prcache eviction functions
Fix callers of the prcache eviction functions - they should be calling
evict_*() from the prcache object.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 13 Aug 2014 12:57:50 +0000 (13:57 +0100)]
Limit a multivalued param that is followed by another required param
A multivalued parameter that is followed by another required parameter is
limited to a single value unless prefaced with its switch, eg:
pts adduser A B C D
B, C and D are group names and A is a user name, despite the user name field
taking multiple values. In contrast in:
pts adduser -user A B -group C D
A and B are users and only C and D are groups.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 12 Jun 2014 08:32:20 +0000 (09:32 +0100)]
Don't log from the bash_complete script
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 12 Jun 2014 08:19:23 +0000 (09:19 +0100)]
Fix some variable deletions in the bash autocomplete handling
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 20 May 2014 23:04:29 +0000 (00:04 +0100)]
Provide bash completion
Provide bash completion that uses the argument lists in the individual
subcommand files to work out how to complete. The completion algorithm will
interpolate required flags first and will fully expand flag names. Flag
parameters will be switched to hostname expansion or cellname expansion as
appropriate.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 15:27:41 +0000 (16:27 +0100)]
Add a Developer's Certificate of Origin
Add a Developer's Certificate of Origin for the use of people submitting
patches.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 13:56:36 +0000 (14:56 +0100)]
Implement "pts setmax"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 13:22:32 +0000 (14:22 +0100)]
Implement "pts setfields"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 12:42:37 +0000 (13:42 +0100)]
Implement "pts chown"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 13:07:05 +0000 (14:07 +0100)]
Add methods to evict entries from the PR ID<->Name cache
Add methods to evict entries from the PR ID<->Name cache so that interactive
mode can make use of it.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 12:29:51 +0000 (13:29 +0100)]
Implement "pts rename"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 11:07:42 +0000 (12:07 +0100)]
Implement "pts creategroup"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 15 May 2014 10:28:59 +0000 (11:28 +0100)]
Implement "pts adduser" and "pts removeuser"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 14 May 2014 12:03:00 +0000 (13:03 +0100)]
Implement "pts membership"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 20:47:42 +0000 (21:47 +0100)]
Implement "pts examine"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 14 May 2014 11:14:52 +0000 (12:14 +0100)]
Provide a protection DB Name<->ID cache
Provide a protection DB Name<->ID cache to eliminate redundant lookups and to
reduce the number of NameToID and IDToName RPC calls made by consolidating
multiple requests into single calls.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 14 May 2014 10:47:18 +0000 (11:47 +0100)]
Add a verbosef() display function
Add a verbosef() display function to do formatted verbose output.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 20:16:05 +0000 (21:16 +0100)]
Implement "pts listowned"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 20:27:56 +0000 (21:27 +0100)]
Better iterate over list of ptservers upon failure
Separate out the iteration over a list of ptservers when one fails. We don't
want to have to intermingle it with a loop over a list of calls to make (eg. a
list of IDs to be deleted).
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 20:24:30 +0000 (21:24 +0100)]
rxgen: Always check type of objects in a bulk list when encoding arguments
We should always check the type of the objects in a bulk list when we're
encoding them as part of an argument (or result) list. Previously we only did
this when we needed to fold things like arrays of ints into an object.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 20:20:08 +0000 (21:20 +0100)]
rxgen: Integer INOUT args should take an int in PyArg_ParseTuple()
Integer INOUT args should take an int in PyArg_ParseTuple() rather than an
arbitrary object as the code now doesn't pass results back through the argument
list.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 20:18:07 +0000 (21:18 +0100)]
rxgen: Support INOUT bulk and struct rpc call args
We can support INOUT bulk and struct rpc call args since the code now doesn't
try to return results through the argument list.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 18:36:50 +0000 (19:36 +0100)]
Implement "pts listmax"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:43:30 +0000 (17:43 +0100)]
Implement "pts listentries"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:40:23 +0000 (17:40 +0100)]
Fix the help-on-help text
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 14:59:37 +0000 (15:59 +0100)]
Implement "pts delete"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 12 May 2014 12:03:07 +0000 (13:03 +0100)]
Implement "pts createuser"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:28:11 +0000 (17:28 +0100)]
Handle exit codes better
Returning the intended exit code from the main try block that invokes the
subcommand handler rather than trying to exit within the exception handling
seems to work better and actually return the error code.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:26:40 +0000 (17:26 +0100)]
Handle negative numeric command line arguments
Handle negative numeric command line arguments, distinguishing them from flags
that begin with dashes.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 14:02:16 +0000 (15:02 +0100)]
Add parsing for the CellServDB file
Add parsing for the CellServDB file if the DNS doesn't throw up AFSDB or SRV
records for volume location database servers.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 13:27:58 +0000 (14:27 +0100)]
Use the Python ipaddress module to represent IP addresses
Use the Python ipaddress module to represent IP addresses internally rather
than trying to do it myself.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:23:37 +0000 (17:23 +0100)]
rxgen: Handle bulk arguments correctly
Need to check for a bulk-class argument of an integer-type before testing for
the integer-type otherwise the integer-type is selected. This causes the wrong
argument spec to be emitted for PyArg_ParseTuple() when decoding the arguments
for an RPC call to be issued.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 10 May 2014 09:44:10 +0000 (10:44 +0100)]
rxgen: Reset call->need_size for each bulk element
We need to reset call->need_size each time the decode phase for a bulk item
repeats as the value is now whittled down by rxrpc_post_dec().
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:33:51 +0000 (17:33 +0100)]
rxgen: Check call->more_recv instead of checking MSG_MORE in rxrpc_recv_data()
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:32:04 +0000 (17:32 +0100)]
Pass the right value to verbose() in bos/adduser.py
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 13 May 2014 16:30:45 +0000 (17:30 +0100)]
Fix the output of "vos listvldb"
Fix the output of "vos listvldb" in the following ways:
(1) Print a blank line between records in the output.
(2) Adjust the indentation.
(3) Don't print RW/RO/Backup volume IDs if the corresponding VLSF_xxVOL
flag is not set.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 1 May 2014 14:53:03 +0000 (15:53 +0100)]
Implement "bos getlog" and reengineer the decode path somewhat
Implement the "bos getlog" subcommand - which requires making the receive side
of split RPC function work. To this end, the following reengineering has been
done to the decode side:
(1) Lift the requirement that the Rx buffer cursor be 4-byte aligned as
BOZO.GetLog() doesn't align the log data it returns.
(2) Permit a request for an unknown - and possibly zero - amount of data to be
set in call->need_size. BOZO.GetLog() doesn't tell you in advance how
much data it will return: the data stops when the Rx receive phase ends
with LAST_PACKET being flagged.
(3) Separate blob decoding (strings & opaques) from bulk decoding in the
member variables of the rx_call struct, where a bulk decode is now a
sequence of blobs, structs or ints.
(4) Handle blob decoding asynchronously, where the buffer into which a blob is
being written may not represent contiguous memory. This is done by
setting up with an init function, called once, and a decode-into function,
called repeatedly whilst it returns 1. The function is only called when
there is sufficient data in the receive buffers.
(5) Decode padding asynchronously by working out up front for a blob how much
padding it requires and then decoding it as its own blob at the end using
a special source buffer as a marker to switch processing.
(6) Perform split reception by adding additional states within the decode
state machine to call out to the handler functions.
The receive() method of the split_handler class provided to a split RPC
function then implements its own state machine on top of the decoder state
machine.
Further:
(*) rxrpc_recv_data() now reports ENODATA rather than EMSGSIZE if the receive
phase ends with short data.
(*) MSG_MORE handling has separate rx_call struct members for the send and
receive phase now to avoid confusion.
(*) rxrpc_enc/dec_slow() now use rxrpc_enc/dec_blob() to avoid duplicating a
lot of code.
(*) rxrpc_enc/dec() now also go to the slow path if the cursor is misaligned,
which may mean the data to be read is split across buffers.
(*) The rx_call struct now has a pointer to a cleanup function to clean up the
decoder state at the end to deal with aborted calls.
(*) rxrpc_post_dec() reduces call->need_size as well as call->data_count as we
don't want to be waiting for N bytes to turn up for a size-N blob if we
have already received N-1 bytes of it and only need one more byte.
This does mean that call->need_size may need resetting more often.
(*) Added an output_raw() python output method to permit bytearray objects to
be printed. Conversion to a string means that control characters and
quotes get escaped (eg. a newline char gets converted to \n).
(*) Catching the SystemExit exception should not produce an error due to ret
not existing as a variable.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Thu, 1 May 2014 14:31:58 +0000 (15:31 +0100)]
Implement "bos setrestricted"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 30 Apr 2014 12:51:14 +0000 (13:51 +0100)]
Implement "bos setrestart"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 29 Apr 2014 21:44:46 +0000 (22:44 +0100)]
Implement "x help" and "x apropos" for all command sets (bos, vos, ...)
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 29 Apr 2014 21:18:25 +0000 (22:18 +0100)]
Implement "bos removekey"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 29 Apr 2014 18:12:26 +0000 (19:12 +0100)]
Implement "bos addkey"
Implement "bos addkey". This requires the Kerberos library for the
string-to-key password transformation.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 16 Apr 2014 07:51:22 +0000 (08:51 +0100)]
Implement "bos listkeys"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 16:25:09 +0000 (17:25 +0100)]
Implement "bos uninstall"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 16 Apr 2014 07:20:08 +0000 (08:20 +0100)]
Implement "bos install"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 15 Apr 2014 08:34:42 +0000 (09:34 +0100)]
rxgen: Implement the transmission side of split-mode RPC calls
Implement the transmission side of RPC calls that are marked with a 'split'
flag - ie. functions in which the caller is allowed to interpolate an
arbitrary transmission blob after the arguments and to receive an arbitrary
blob before the response is received.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Wed, 16 Apr 2014 07:18:07 +0000 (08:18 +0100)]
rxgen: Use PyErr_NoMemory() rather than PyExc_MemoryError
Use PyErr_NoMemory() rather than PyExc_MemoryError as the former actually
raises an exception. The latter is just a class and is then just an object
with no special meaning when returned.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 15 Apr 2014 09:42:23 +0000 (10:42 +0100)]
rxgen: Fix rxrpc_send_data()
Make three Fixes to rxrpc_send_data():
(1) Advance to the next buffer when filling the iovec array rather than
endlessly cycling over the first one.
(2) Only clear MSG_MORE if we have sent all the buffered data at the end of
the transmission phase of a call.
(3) Don't turn the return value of sendmsg() into just -1 or 0 as we need the
number of bytes actually sent to allow us to correctly advance the buffer
cursor.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Tue, 15 Apr 2014 09:52:32 +0000 (10:52 +0100)]
rxgen: Clean up the debugging in the AF_RXRPC driver a bit
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 15:56:25 +0000 (16:56 +0100)]
Implement "bos prune"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 16:11:46 +0000 (17:11 +0100)]
Fix argument non-combination checking
David Howells [Mon, 14 Apr 2014 15:31:06 +0000 (16:31 +0100)]
Implement "bos exec"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 15:18:59 +0000 (16:18 +0100)]
Implement "bos restart"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 15:08:57 +0000 (16:08 +0100)]
Implement "bos setauth"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 14:23:15 +0000 (15:23 +0100)]
Mark accesses to global vars in addrcache as 'global'
Mark accesses to global vars in the addrcache module as 'global' to make sure
Python doesn't do local access instead.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 12:42:41 +0000 (13:42 +0100)]
Fix up output and error displaying in commands
Fix up output and error displaying in commands so far implemented. Replace
usage of print() with output() and outputf() for normal operation and error()
for error display. debug() is replaced with verbose() which is contingent on
the -verbose switch.
Also add error handling to a number of commands.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 08:23:54 +0000 (09:23 +0100)]
Provide argument exception class and check argument length restrictions
Create an argument error class specifically for the indication of command line
argument problems and catch it in main.py.
Further, provide checking for string arguments that have length restrictions
in the protocol.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 07:46:45 +0000 (08:46 +0100)]
rxgen: Check maximum length of parameter string or opaque
Check the maximum length of string or opaque parameter to a function and raise
an exception if it is too long.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Mon, 14 Apr 2014 07:09:58 +0000 (08:09 +0100)]
rxgen: The abort table comparator needs to handle big numbers
The abort table comparator needs to handle big numbers (larger than
0x7fffffff). Subtracting a small number from such a big number and then
casting to a signed int results in a negative number, which bsearch()
interprets as indicating that the bigger number is smaller than the smaller
number.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sun, 13 Apr 2014 11:46:16 +0000 (12:46 +0100)]
Implement "bos {adduser,removeuser}"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 20:06:37 +0000 (21:06 +0100)]
Implement "bos removehost"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 19:50:10 +0000 (20:50 +0100)]
Implement "bos {startup,shutdown}"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 16:47:54 +0000 (17:47 +0100)]
Implement "bos {start,stop}" and make "bos delete" handle multiple instances
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 14:53:25 +0000 (15:53 +0100)]
Implement "bos delete"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 13:58:29 +0000 (14:58 +0100)]
Implement "bos create"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 14:52:45 +0000 (15:52 +0100)]
Preface AFS error messages with the program name
When printing an error message passed through AFSException, preface it with
the name the program was run as.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 14:51:03 +0000 (15:51 +0100)]
Provide separate arg interpretation functions for multivalued arguments
Provide separate arg interpretation functions for multivalued arguments so
that the single-valued versions return a non-list and the multivalued returns
a list.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 13:36:28 +0000 (14:36 +0100)]
Implement "bos addhost"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 13:33:46 +0000 (14:33 +0100)]
Use gethostbyname_ex() and gethostbyaddr() rather than the DNS resolver
Use gethostbyname_ex() and gethostbyaddr() for A and PTR record retrieval
rather than using the DNS resolver directly so that /etc/hosts and suchlike
are also used.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Sat, 12 Apr 2014 12:59:34 +0000 (13:59 +0100)]
Implement "bos setcellname"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 23:29:02 +0000 (00:29 +0100)]
Implement "bos getrestricted"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 23:03:15 +0000 (00:03 +0100)]
Implement "bos getrestart"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 16:39:28 +0000 (17:39 +0100)]
Implement "bos status"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 22:57:53 +0000 (23:57 +0100)]
rxgen: The string and bytes decode functions must advance the cursor
The string and bytes decode functions (py_dec_string() and rxrpc_dec_bytes())
need to advance the extraction cursor after extracting so the data doesn't get
reused.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 16:28:56 +0000 (17:28 +0100)]
Implement "bos listusers"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 16:04:43 +0000 (17:04 +0100)]
Implement "bos getdate"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 15:46:18 +0000 (16:46 +0100)]
Implement "bos listhosts" and "bos getcell"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 15:35:02 +0000 (16:35 +0100)]
Create AFS standard date and time format library module
Create an python library module to format date and times in the AFS standard
way.
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 14:15:39 +0000 (15:15 +0100)]
Implement "vos monitor"
Signed-off-by: David Howells <dhowells@redhat.com>
David Howells [Fri, 11 Apr 2014 14:10:03 +0000 (15:10 +0100)]
Clean up unnecessary imports
Signed-off-by: David Howells <dhowells@redhat.com>