Documentation ¶
Overview ¶
Package webdav provides a splitFs webdav implementation. This is a way to make the data available for end user.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFileSystem ¶
func NewFileSystem(service interf.Service, dbKey []byte, debugLvl uint8, updateInterval int) webdav.FileSystem
NewFileSystem creates a new webdav file system. It provides the plaintext data and accesses a storage in the background.
'service' is used to access the encrypted parts in the background. 'dbKey' is the key to the database file (stored online). 'debugLvl' controls the print output (@see impl.DebugOff, impl.DebugLow and impl.DebugHigh). 'updateInterval' in seconds controls how often database is updated in the background. The value 0 deactivates the update loop.
func Serve ¶
func Serve(lAddr string, useTls bool, certFile string, certKeyFile string, fs webdav.FileSystem, userFile string, debugLvl uint8) error
ServeTLS accepts incoming HTTPS connections on the listener, creating a new service goroutine for each. The service goroutines read requests and then call handler to reply to them.
If the lAddr is empty or a literal unspecified IP address, Listen listens on all available unicast and anycast IP addresses of the local system. The address can use a host name, but this is not recommended, because it will create a listener for at most one of the host's IP addresses. If the port in the address parameter is empty or "0", as in "127.0.0.1:" or "[::1]:0", a port number is automatically chosen.
Additionally, files containing a certificate and matching private key for the server must be provided. If the certificate is signed by a certificate authority, the certFile should be the concatenation of the server's certificate, any intermediates, and the CA's certificate.
ServeTLS always returns a non-nil error.
Types ¶
This section is empty.