Document the URL syntax

libnfs-4.0.0-vitalif
Ronnie Sahlberg 2013-12-25 16:27:10 -08:00
parent 6d89ace041
commit 0961765a56
2 changed files with 33 additions and 0 deletions

15
README
View File

@ -23,6 +23,21 @@ stat(), read(), ...
examples/nfsclient-sync.c provides examples on how to use this API
URL-FORMAT:
===========
Libnfs uses RFC2224 style URLs extended with libnfs specific url arguments some minor extensions.
The basic syntax of these URLs is :
nfs://<server|ipv4>/path[?arg=val[&arg=val]*]
Arguments supported by libnfs are :
tcp-syncnt=<int> : Number of SYNs to send during the seccion establish
before failing settin up the tcp connection to the
server.
uid=<int> : UID value to use when talking to the server.
default it 65534 on Windows and getuid() on unixen.
gid=<int> : GID value to use when talking to the server.
default it 65534 on Windows and getgid() on unixen.
ROOT vs NON-ROOT

View File

@ -111,6 +111,24 @@ EXTERN struct nfs_context *nfs_init_context(void);
EXTERN void nfs_destroy_context(struct nfs_context *nfs);
/*
* URL parsing functions.
* These functions all parse a URL of the form
* nfs://server/path/file?argv=val[&arg=val]*
* and returns a nfs_url.
*
* Apart from parsing the URL the functions will also update
* the nfs context to reflect settings controlled via url arguments.
*
* Current URL arguments are :
* tcp-syncnt=<int> : Number of SYNs to send during the seccion establish
* before failing settin up the tcp connection to the
* server.
* uid=<int> : UID value to use when talking to the server.
* default it 65534 on Windows and getuid() on unixen.
* gid=<int> : GID value to use when talking to the server.
* default it 65534 on Windows and getgid() on unixen.
*/
/*
* Parse a complete NFS URL including, server, path and
* filename. Fail if any component is missing.