Over The Wire Bandit Level 16 → Level 17 Difficulties
好的,我现在需要帮用户总结一篇文章的内容,控制在100字以内,并且不需要特定的开头。首先,我得仔细阅读用户提供的文章内容。 这篇文章看起来是关于一个用户在玩OverTheWire的Bandit游戏时遇到的问题。用户提到自己是一个新手,在第16关卡住了,尝试了多个教程但还是无法解决。问题主要集中在创建临时目录并保存密钥到其中,使用vim或nano工具。用户尝试了mkdir、cd、touch、chmod等命令,但连接到第17关时遇到了权限问题和端口问题。 用户在尝试ssh连接时,系统提示无法创建.ssh目录,权限被拒绝。此外,用户还尝试了不同的端口(22和2220),但仍然无法连接。系统提示从localhost连接被阻止,并且没有启用认证方法。 总结一下,用户的问题包括:权限问题导致无法创建.ssh目录,端口选择错误(可能需要特定的端口),以及可能的密钥格式或位置问题。 接下来,我需要将这些信息浓缩到100字以内。重点是描述用户遇到的问题:创建临时目录保存密钥后,无法通过SSH连接到下一关卡,遇到权限和端口错误。 所以,总结应该是:用户在Bandit游戏中卡在第16关,尝试创建临时目录保存密钥后仍无法连接到第17关,遇到权限和端口错误。 现在检查字数是否在限制内,并确保语言简洁明了。 </think> 文章描述了一个新手在OverTheWire Bandit游戏的第16关中遇到的问题。尽管按照教程创建了临时目录并保存了密钥,但在尝试通过SSH连接到第17关时遇到了权限被拒绝和端口错误的问题。 2026-2-2 12:44:24 Author: www.reddit.com(查看原文) 阅读量:0 收藏

I'm a beginner and I completely stuck on this lvl. I've tried and followed along like 5 tutorials and it's still wrong.

The problem is not about getting the KEY, but about creating a temporary directory and saving the key via /nano or /vim.

Here, with vim(i can add with nano), from the site https://david-varghese.medium.com/overthewire-bandit-level-16-level-17-c137701b3af1 )

dxviW8+TFVEBl1O4f7HVm6EpTscdDxU+bCXWkfjuRb7Dy9GOtt9JPsX8MBTakzh3

vBgsyi/sN3RqRBcGU40fOoZyfAMT8s1m/uYv52O6IgeuZ/ujbjY=

-----END RSA PRIVATE KEY-----

^C

bandit16@bandit:~$ mkdir /tmp/random_sshkey

bandit16@bandit:~$ cd /tmp/random_sshkey

bandit16@bandit:/tmp/random_sshkey$ touch private.key

bandit16@bandit:/tmp/random_sshkey$ vim private.key

bandit16@bandit:/tmp/random_sshkey$ chmod 400 private.key

bandit16@bandit:/tmp/random_sshkey$ ls -l

total 4

-r-------- 1 bandit16 bandit16 1675 Feb 2 12:31 private.key

So far so good, but then I try to connect to 17lvl:

bandit16@bandit:/tmp/random_sshkey$ ssh -i private.key bandit17@localhost

The authenticity of host 'localhost (127.0.0.1)' can't be established.

ED25519 key fingerprint is SHA256:C2ihUBV7ihnV1wUXRb4RrEcLfXC5CXlhmAAM/urerLY.

This key is not known by any other names.

Are you sure you want to continue connecting (yes/no/[fingerprint])? yes

Could not create directory '/home/bandit16/.ssh' (Permission denied).

Failed to add the host to the list of known hosts (/home/bandit16/.ssh/known_hosts).

This is an OverTheWire game server.

More information on http://www.overthewire.org/wargames

!!! You are trying to log into this SSH server on port 22, which is not intended.

!!! If you are trying to log in to an OverTheWire game, use the port mentioned in

!!! the "SSH Information" on that game's webpage (in the top left corner).

bandit17@localhost: Permission denied (publickey).

AGAIN:

bandit16@bandit:/tmp/random_sshkey$ ssh -i private.key -p 2220 bandit17@localhost

The authenticity of host '[localhost]:2220 ([127.0.0.1]:2220)' can't be established.

ED25519 key fingerprint is SHA256:C2ihUBV7ihnV1wUXRb4RrEcLfXC5CXlhmAAM/urerLY.

This key is not known by any other names.

Are you sure you want to continue connecting (yes/no/[fingerprint])? yes

Could not create directory '/home/bandit16/.ssh' (Permission denied).

Failed to add the host to the list of known hosts (/home/bandit16/.ssh/known_hosts).

This is an OverTheWire game server.

More information on http://www.overthewire.org/wargames

!!! You are trying to log into this SSH server with a password on port 2220 from localhost.

!!! Connecting from localhost is blocked to conserve resources.

!!! Please log out and log in again.

backend: gibson-1

Received disconnect from 127.0.0.1 port 2220:2: no authentication methods enabled

Disconnected from 127.0.0.1 port 2220

I am completely stuck and can't understand what is wrong. I've tried it with port 22/2220, different folders names, sshkey.private and so on, still doesn't work


文章来源: https://www.reddit.com/r/HowToHack/comments/1qtu1tu/over_the_wire_bandit_level_16_level_17/
如有侵权请联系:admin#unsafe.sh