我最近一直在使用尸体,但有没有办法自动login,例如一个class轮:
尸体http://webdav.server.com user = xxxxxxxxx pass = xxxxxxxxxxx
我不能使用davfs2,因为我的VPS不会安装WebDav,因为它符合FUSE。
您可以使用.netrc文件,但请注意这是一个安全风险。 它包含没有encryption的dav帐户的密码。 您需要使用的一些预防措施是:
这里是来自尸体手册页的netrc的信息。
THE .netrc FILE The file ~/.netrc may be used to automatically login to a server requiring authentication. The following tokens (separated by spaces, tabs or newlines) may be used: machine host Identify a remote machine host which is compared with the hostname given on the command line or as an argument to the open command. Any subsequent tokens up to the end of file or the next machine or default token are associated with this entry. default This is equivalent to the machine token but matches any hostname. Only one default token may be used and it must be after all machine tokens. login username Specifies the username to use when logging in to the remote machine. password string passwd string Specifies the password to use when logging in to the remote machine. Any other tokens (as described in ftp(1)) are ignored.
祝你好运,Rik