作者:梁利锋 标签:杂谈

3679天前 (阅读:5419)
  最近使用ssh,主要是为vnc提供一条加密通道,装了cygwin,然后其他机器也要用,本来以为cygwin肯定是绿色软件,没成想复制过去的完整的cygwin目录,却不能正确执行,搜索了一下,发现cygwin要使用注册表,只要把下面的注册表文件导入,就可以使用了:
Windows Registry Editor Version 5.00


[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions]

[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin]

[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2]
"cygdrive prefix"="/cygdrive"
"cygdrive flags"=dword:00000022

[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/]
"native"="C:\\cygwin"
"flags"=dword:0000000a

[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/usr/bin]
"native"="C:\\cygwin/bin"
"flags"=dword:0000000a

[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/usr/lib]
"native"="C:\\cygwin/lib"
"flags"=dword:0000000a

[HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\Program Options]

  不过,再想想,其实我并不需要使用完整的cygwin,而只是需要ssh罢了,那么只提取ssh怎么样呢?使用cmd启动ssh,运行正常,于是把ssh相关的执行文件复制出来,提取出一个portable ssh,可以直接执行,不需要修改注册表,下面是文件列表:
cygcrypto-0.9.8.dll
cygminires.dll
cygwin1.dll
cygz.dll
ssh-add.exe
ssh-agent.exe
ssh-host-config
ssh-keygen.exe
ssh-keyscan.exe
ssh-user-config
ssh.exe

If I communicated I could thank you enuogh for thi(非注册用户) 2012-10-23 5:28:09

If I communicated I could thank you enuogh for this, I'd be lying.

I can't believe you're not playing with metah--t w(非注册用户) 2015-1-19 23:53:58

I can't believe you're not playing with metah--t was so helpful.