如何使用ssh-hop从windows转发密钥

kaneda99提供的图像。...

如何使用ssh-hop从windows转发密钥 Do you have the need to work with SSH keys from Windows and you find that this becomes a hassle very quickly? HTG goes into how to make the process as transparent as possible, using The PuTTY package suite.

kaneda99提供的图像。

概述

在本指南中,我们将解释如何使用Putty&Winscp使用公钥从Windows SSH到Linux机器。此外,我们将启用转发选项。这将允许您继续从用密钥连接的机器跳转到另一台支持用密钥进行SSHing的机器。我们将不讨论如何在Linux机器上放置公钥,因为我们已经讨论了这个主题。

安装基本程序/软件包

  • 获取PuTTY包(不仅仅是可执行文件)并安装它。
  • (可选)获取程序WinSCP和mRemote,并安装它们。

Generate a Key pair

If you haven’t created a key pair yet, and you want to do it from the comfort of your Windows desktop, you can use “PuTTY Key Generator” which was installed as part of the “PuTTY package“:

  • Open “PuTTY Key Generator” by going into “Start” -> “PuTTY” -> “PuTTYgen”
  • While not required, it is recommended that you change the length of your key from the default 1024. Change the number of “bits” at the bottom from “1024” to “4096”.
  • Click “Generate” and move your mouse around randomly until the bar reaches 100%. This “salts” your key, so try to make your mouse movements as random as possible. 007Ys3FFgy1gpgg4zg1lsj30dp0dat9e
  • Once the program is done generating the key,
  • On the “Key Comment” line, change it to be something more useful like your name. For example: 007Ys3FFgy1gpgg500n3sj30dp06hq3g
  • While not required, it is highly recommended that you set a passphrase on the private key. This will protect your private key in case some one gains access to it and you will only be bothered with entering once at machine boot up, if you perform all the steps in the guide.
  • Click on “Save private key”.

Note: If you already have a saved private key, you can “extract” the public portion by “load”ing it with the generator.

Configuring the Key-quartermaster

The “Pageant” program that was installed as part of the PuTTY package, can store your key/s and give them to mRemote, WinSCP and PuTTY as required.

  • Open “Pageant” from the start menu. (Note: it may run off to the system tray) 007Ys3FFgy1gpgg50l6e0j30e70a5wet
  • If it has run off to the system tray, double click it, to bring up the main window.
  • Click “Add Key” and give it your saved Key Pair.
  • If need be, provide the passphrase.

Done, from now on, Putty, WinSCP and any program that serves as a fronted for them (like mRemote) will first c***ult with the Pageant program if there is a key to use for the connection.

Loading Keys automatically at startup (Optional)

The process above needs to be repeated after every machine reboot, as Pageant doesn’t save loaded key configurati***. To have it load the configuration automatically at startup, you can use one of the two methods below:

  1. Assuming you’ve allowed Pageant to take over the ppk suffix, you should be able to simply add the key files to the Windows “startup” folder.
  2. Create a shortcut to the program that passes the key-files as parameters.  For example, the “Target” command for two(2) keys would look like: 007Ys3FFgy1gpgg514t97j30bc06e0sv “C:\Program Files (x86)\PuTTY\pageant.exe” “C:\Users\AviadR\Documents\aviad’s 4096.ppk”  “C:\Users\AviadR\Documents\aviad’s 1024.ppk
  • Then, add this shortcut to window’s startup.

Enable SSH Agent forwarding (PuTTY/mRemote)

此配置是可选的,但这样做将允许您在SSH到一台计算机后继续,并使用相同的密钥从它SSH到下一台计算机。为此:

  • 打开油灰。
  • 在“Connection”->“SSH”->“Auth”下。
  • 选中“允许代理转发”。
  • 返回“会话”
  • 选择“默认设置”项。
  • 点击“保存”。
  • 完成。

启用SSH代理转发(WinSCP)

  • In a WinSCP new connection tab, Enable the Advance opti*** checkbox.
  • Go to the “SSH” -> “Authentication”.
  • Check the “Allow agent forwarding” checkbox. 007Ys3FFgy1gpgg51nvdfj30em0abq3u
  • Go to the “General Opti***” by clicking on “Preferences” -> “Preferences”. 007Ys3FFgy1gpgg527vltj30eo0adt9n
  • Enable Putty to be invoked with the  forwarding option by going into “Integration” -> “Application” and appending the “-A” CLI option. 007Ys3FFgy1gpgg52sxzdj30eq0c5js9
  • You can now make this the template for subsequent connecti*** by going back to “Session” and typing in, the basic information that you know will be uniform across all connecti*** (if any), like Username, IP, Etc’. Then “save” the session.

Author’s Notes

While purists, will say that any serious SSHing, should be done from a Linux machine, the reality is that Ubuntu’s bug #1 “Microsoft has a majority desktop market share”, still holds true. maybe one day we’ll move to the Linux desktop completely, but that day will not be today and not for the 35 year old shell.


斯派克:所以我想我服刑了,我可以走了?声波:自由行动,塞伯坦…

  • 发表于 2021-04-12 04:08
  • 阅读 ( 202 )
  • 分类:互联网

你可能感兴趣的文章

用堡垒主机保护您的网络只需3个步骤

... 你们中的精明人可能想知道如何通过互联网接入家庭路由器。大多数internet服务提供商(ISP)都会为您分配一个临时IP地址,该地址经常更改。如果你想要一个静态IP地址,ISP往往会额外收费。好消息...

  • 发布于 2021-03-12 01:44
  • 阅读 ( 340 )

如何加密您的gmail、outlook和其他Web邮件

...。他们掌握着你的数字王国以及个人信息的钥匙。这是你如何加密你的Gmail,Outlook.com,以及其他电子邮件帐户。 ...

  • 发布于 2021-03-21 20:27
  • 阅读 ( 254 )

什么是windows 10通用产品密钥?下面是如何使用它们

... 您也可以查看我们的指南如何获得视窗10免费。 ...

  • 发布于 2021-03-30 02:21
  • 阅读 ( 392 )

键盘的媒体键在所有现代网络浏览器中都能工作

...Safari和Edge中的YouTube、Spotify以及其他视频和音乐网站。 如何在网站上使用媒体密钥 使用媒体键应该很简单:只需按下它们。例如,如果您正在播放一段YouTube视频,而该视频隐藏在某个背景选项卡中,则可以按键盘上的“播放/...

  • 发布于 2021-04-01 10:04
  • 阅读 ( 219 )

如果没有windows密钥,如何创建该密钥

...过借用一个不经常使用的键来“添加”一个键盘。下面是如何做到这一点。 使用微软的免费PowerToys实用程序,你可以很容易地重新分配任何键,使其与其他键一样工作(甚至给它们一个新的功能,如静音你的音频)。在本例中...

  • 发布于 2021-04-01 21:05
  • 阅读 ( 226 )

如何使用命令提示符查找windows 10产品密钥

...以通过在命令提示符下输入快速命令来找到它。下面介绍如何使用Windows注册表方法查找产品密钥。 使用命令提示符查找windows 10产品密钥 要使用命令提示符查找Windows10产品密钥,您需要以管理权限打开命令行应用程序。为此,...

  • 发布于 2021-04-02 13:00
  • 阅读 ( 275 )

如何在硬件更改后重新激活Windows10

...到更好的组件和Windows10只是不承认你的电脑?本指南介绍如何在硬件更改后重新激活Windows10。 什么算硬件更改? 这是一个连微软都无法完全解释的领域。相反,公司在其网站上提供以下声明: “If you make significant hardware changes o...

  • 发布于 2021-04-03 00:28
  • 阅读 ( 205 )

使用aws保护您的家庭minecraft服务器免受ddos攻击

...运行Minecraft服务器而不暴露你的IP地址吗?你可以!只需使用amazonwebservices设置一个免费代理,就可以保护您的服务器免受拒绝服务攻击。我们会教你怎么做。 本指南适用于任何游戏服务器,而不仅仅是Minecraft。它所做的只是特...

  • 发布于 2021-04-03 03:34
  • 阅读 ( 289 )

什么是反向ssh隧道?(以及如何使用)

...用隧道。 所以我们得到了“反向SSH隧道”这个名字 它是如何工作的? 反向SSH隧道依赖于远程计算机使用已建立的连接来侦听来自本地计算机的新连接请求。 远程计算机监听本地计算机上的网络端口。如果它检测到对该端口的SS...

  • 发布于 2021-04-03 08:32
  • 阅读 ( 213 )

如何保护bitlocker加密文件免受攻击者攻击

...,这种设备加密技术比完整的BitLocker更为有限。 攻击者如何利用此漏洞:不需要利用漏洞!如果您的Windows Home PC未加密,攻击者可以删除硬盘驱动器或启动PC上的其他操作系统来访问您的文件。 解决方案:支付99美元升级到Window...

  • 发布于 2021-04-03 18:41
  • 阅读 ( 200 )
帅气无敌就是哥
帅气无敌就是哥

0 篇文章

相关推荐