Protocol/tcp/ip protocol2014. 8. 12. 16:44

복사 http://blog.naver.com/ksh81850/220003454989


● 일반적인 인터넷

 

- TCP/IP 프로토콜을 사용한다.

- 프로토콜 : 다양한 Network 장치들이 서로 데이터를 교환할수 있도록 도와주는 일종의 약속

- 원격지에 있는 Host 상호간 정확하고 효율적으로 데이터 전송에 필요한 모든 약속.

- Host : 네트워크에 연결된 컴퓨터를 의미

● 다양한 운영체제

- 유닉스, 리눅스, 윈도우 등 다양한 운영체제는 사용하는 네트워크가 각각 다른 형태이다. 때문에 서로 데이터 공유가 어렵다. 이러한 문제 해결을 위한 것이 TCP/IP 프로토콜이다.

- 현 모든 데이터가 TCP/IP 프로토콜에서 약속된 형태로 전송되므로 운영체제 및 시스템에 상관없이 데이터 교환 가능하다.

 

● TCP/IP의 기본적인 특징

- 네트워크 기술의 독립성

- 시스템과 운영체제 관계없이 통신 가능

- 전송 데이터의 규격 표준화.

 

- 임의의 상호 접속

- 네트워크 연결된 시스템 상호간 인식 가능한 고유의 주소 할당.

- 고유의 주소를 통한 컴퓨터간 통신 가능

 

- 송 . 수신자의 응답

- 각개의 송.수신자가 별개의 네트워크에 존재한들, 데이터 교환 가능

 

- 공통의 응용 프로그램 제공

- TCP/IP 규격에 맞는 응용 프로그램 다수 존재

- 해당 프로그램 사용시 어디든 통신 가능

 

● OSI 7계층구조

- 국제 표준화 기구(ISO: International Standards Organization)는 서로 다른 시스템간의 원활한 통신을 위해 OSI(Open System Interconnection) 7계층이라는 프로토콜 제정.

- 다음과 같은 구조로 구성되어 있다.

 용 계층(Application Layer)

 현 계층(Presentation Layer)

 션 계층(Session Layer)

 전송 계층(Transport Layer)

 트워크 계층(Network Layer)

 이터 링크 계층(Datalink Layer)

리 계층(Physical Layer)

- 필자는 다음 7개의 계층의 순서를 '물데네트세표응' 이란 순서로 외웠다.

- 위의 7계층은 실제 사용보다 프로토콜 개발에 필요로한 표준의 성향이 크다.

● TCP/IP 계층구조

-OSI 7계층은 실 사용보다 프로토콜 개발하는데 필요한 성향이 크다. 실 인터넷 사용하는 프로토콜은 TCP/IP이다.

- TCP/IP는 기능별로 4계층으로 구성되어있다.

 계층

기능 

응용 계층(Application Layer) 

User에게 실제 데이터 전달 기능 

전송 계층(Transport Layer) 

데이터의 신뢰성있는 전송 보장 기능 

인터넷 계층(Internet Layer) 

데이터 전송 경로 정하는 기능 

네트워크 접속 계층

(Network Interface Layer) 

물리적 데이터 전송 방법 정의 

 

- 위 4개의 계층은 하드웨어와 많은 연관이 있다.

- Java를 통해 네트워크 프로그램 개발시 응용 계층(Application Layer)를 주로 다룬다. 패키지는 Java.net.* 패키지를 이용한다

 

● TCP/IP 계층의 프로토콜 종류

- 응용 계층(Application Layer) : SMTP, FTP, Telnet, HTTP, NNTP 등

- 전송 계층(Transport Layer) : TCP, UDP

- 인터넷 계층(Internet Layer) : IP, ICMP

- 네트워크 접속 계층            : Ethernet, 토큰링, X.25, 디지털 회선 등

  (Network Interface Layer)

 

● IP(Internet Protocol)

- 컴퓨터간 통신하기 위해 상대의 정확한 주소(IP 주소) 가 필요

- IP주소는 고유의 번호를 전 세계 컴퓨터에게 부여한 것.

- 상호 연결된 네트워크 통해 데이터 전송하는데 필요한 기능 제공.

- IP의 숫자 외우는 것이 어려워 도메인 네임을 통해 쉽게 접근 가능.

- 널리사용하는IP주소는 IPv4는 000.000.000.000 처럼 값 4개로 구성된 32Bit 주소이다.

- IP주소는 네트워크 식별자와 호스트 식별자로 나뉘어진다.

- IPv4의 한계를 극복하기 위해 만들어 낸것이 IPv6이다.

 

● 인터넷의 클래스

- 네트워크 식별자와 호스트 식별자 크기에 따라 구분한다

- 클래스 A :

- 많은 호스트 가진 큰 네트워크에서 사용.

- 네트워크 식별자 8Bit, 호스트 식별자 24Bit

- 클래스 B :

- LAN과 호스트 포함한 분산 처리 시스템 사용.

- 네트워크 식별자 16Bit, 호스트 식별자 16Bit

- 클래스 C :

- 일반적 LAN과 같은 소규모 네트워크 사용

- 네트워크 식별자 24Bit, 호스트 식별자 8Bit

- 클래스 D :

- 멀티 캐스팅위해 사용

- 네트워크 식별자와 호스트 식별자 구분이 없다

- 클래스 E :

- 장래에 사용하기 위해 사용이 유보

 

● Port 번호

- Port는 물리적 존재하는 연결 통로가 아닌 서비스를 구분하여 처리하기 위한 연결 통로

- IANA의해 예약되거나 이미 정해진 포트(Well-Known Port) - 0 ~ 1023

- IANA의해 등록된 포트 및 일반적 사용자가 사용하게 될 포트 - 1024 ~ 49151

- 동적으로 할당 및 사적으로 사용 될 포트 - 49152 ~ 65535

- 대표적인 Well-Known Port

- HTTP : 80번

- FTP : 21번

- TELNET : 23번

- SMTP : 25번

- Gopher : 70번

※ IANA : Internet Assigned Numbers Authority로서 인터넷 할당 번호 관리 기관이다.

 

● TCP/IP 전송 계층 연결형

- TCP(Transmission Control Protocol) - 패킷(Packet) 단위로 전송

- OSI 4계층(전송계층)과 동일한 기능 담당하는 프로토콜

- 송 수신자가 연결된 상태에서 데이터 전송 가능

- 호스트 사이에 신뢰성 경로 확립하고 메세지 전송 감독 기능

- 수신자가 정상 수신 신호(ACK : Acknowledge). 받지 못하면 에러 발생으로 판단하여 재전송.

- 데이터의 분실, 손상, 중복, 지연, 순서 틀린것 등 발생시, 투명성 보장되는 통신 제공

- 데이터 전송, ACK 신호 전송때문에 UDP에 비해 네트워크 부하가 큼

- 신뢰성 보장되어야 하는 Web, 전자우편, FTP와 같은 서비스에 사용

(FTP, Telnet, SMTP, POP3, HTTP 등)

 

● TCP/IP 전송 계층 비연결형

- UDP(User Datagram Protocol) - 패킷(Packet) 단위로 전송

- 송 수신자 사이 연결시킨 후 데이터를 전송하는 것이 아닌 수신자에게 데이터 전송에 목적을 둠

- 실제 송 수신자 연결 기능은 IP가 담당하므로 전송 계층에 있는 프로토콜은 연결 관리하는 기능 수행(연결 관리 기능이 없다)

- 신뢰성없는 데이터 전송 수행. ACK 신호 사용 하지 않음.

- 데이터 순서, 분실, 중복 등 제어 수행 하지 않음

- 네트워크 부하가 적다.

- 데이터 순서와 신뢰성 중시하지 않고 대량의 데이터 전송하는 서비스에 사용

 



Posted by wrnly
Protocol/url protocol2014. 8. 10. 11:04


Ok, please bear with me as this is sort of difficult to explain.

I have seen...

  • http://www...
  • ftp://blah.blah...
  • file://blah.blah...
  • unreal://blah.blah...
  • mailto://blah.blah...

What is that first section where you see http and the like called?

Can I register my own?

share|improve this question
2 
Not sure if this needs the c# and .net tags, it's broader than that. –  Rob Hruska Dec 23 '08 at 15:50
   
That's fair. I only tagged it that way because we were planning on using C# to implement something like this. Thanks though. :-) –  Michael Beck Dec 23 '08 at 15:57
7 
The correct name is "scheme" (see RFC 2616 and 2396). Even if many URL schemes are named after protocols, this does not imply that the only way to access the resource is via the protocol –  Marek Nov 9 '10 at 11:48

The portion with the HTTP://,FTP://, etc are called URI Schemes

You can register your own through the registry.

HKEY_CLASSES_ROOT/
  your-protocol-name/
    (Default)    "URL:your-protocol-name Protocol"
    URL Protocol ""
    shell/
      open/
        command/
          (Default) PathToExecutable

Sources: https://www.iana.org/assignments/uri-schemes/uri-schemes.xhtml,http://msdn.microsoft.com/en-us/library/aa767914(v=vs.85).aspx

share|improve this answer
3 
What about non-Windows OSes? –  Bdoserror Dec 23 '08 at 17:04
1 
"What about non-Windows OSes?" It's application-specific. I think it's actually frequently application-specific on Windows too (this won't make everything magically work). –  Calum Dec 23 '08 at 17:19
1 
Define everything. The registry entry tells Windows to pass the Uri with that protocol to the application specified, everything else should be handled by the application itself. –  James Gregory Dec 23 '08 at 19:32
3 
Pluggable protocol handler is definitely a better choice. –  Miriam Dec 1 '09 at 17:17
1 
(Default) here means empty string. Don't take it literally. –  deerchao Apr 5 '13 at 9:02

This is different for each browser, in IE and windows you need to create what they call a pluggable protocol handler.

The basic steps are as follows:

  1. Implement the IInternetProtocol interface.
  2. Implement the IInternetProtocolRoot interface.
  3. Implement the IClassFactory interface.
  4. Optional. Implement the IInternetProtocolInfo interface. Support for the HTTP protocol is provided by the transaction handler.
  5. If IInternetProtocolInfo is implemented, provide support for PARSE_SECURITY_URL and PARSE_SECURITY_DOMAIN so the URL security zone manager can handle the security properly. Write the code for your protocol handler.
  6. Provide support for BINDF_NO_UI and BINDF_SILENTOPERATION.
  7. Add a subkey for your protocol handler in the registry under HKEY_CLASSES_ROOT\PROTOCOLS\Handler.
  8. Create a string value, CLSID, under the subkey and set the string to the CLSID of your protocol handler.

See About Asynchronous Pluggable Protocols on MSDN for more details on the windows side. There is also a sample in the windows SDK.

A quick google also showed this article on codeproject:http://www.codeproject.com/KB/IP/DataProtocol.aspx.

Finally, as a security guy I have to point out that this code needs to be battle hardened. It's at a high risk because to do it reliably you can't do it in managed code and have to do it in C++ (I suppose you could use VB6). You should consider whether you really need to do this and if you do, design it carefully and code it securely. An attacker can easily control the content that gets passed to you by simply including a link on a page. For example if you have a simple buffer overflow then nobody better do this: <a href="custom:foooo{insert long string for buffer overflow here}"> Click me for free porn</a>

Strongly consider using strsafe and the new secure CRT methods included in the VC8 and above compilers. See http://blogs.msdn.com/michael_howard/archive/2006/02/27/540123.aspx if you have no idea what I'm talking about.

share|improve this answer
2 
That's just an example of something to entice users to click on it. –  Peter Oehlert Dec 23 '08 at 20:19

Open notepad and paste the code below into it. Change "YourApp" into your app's name. Save it to YourApp.reg and execute it by clicking on it in explorer. That's it! Cheers! Erwin Haantjes

REGEDIT4

[HKEY_CLASSES_ROOT\YourApp]
@="URL:YourApp Protocol"
"URL Protocol"=""

[HKEY_CLASSES_ROOT\YourApp\DefaultIcon]
@="\"C:\\Program Files\\YourApp\\YourApp.exe\""

[HKEY_CLASSES_ROOT\YourApp\shell]

[HKEY_CLASSES_ROOT\YourApp\shell\open]

[HKEY_CLASSES_ROOT\YourApp\shell\open\command]
@="\"C:\\Program Files\\YourApp\\YourApp.exe\" \"%1\" \"%2\" \"%3\" \"%4\" \"%5\" \"%6\" \"%7\" \"%8\" \"%9\""
share|improve this answer
   
how to call from explorer, what is the url –  imp Jun 17 at 10:27
   
@imp, it is not a smart idea to call .reg files from (internet) explorer. You can use the start command to execute a reg file, like 'start yourregfile.reg' but you will get a prompt message from the os to be sure to add it to the registry. To able to this the user must have admin privileges. –  Erwinus Jun 18 at 1:05
   
Actually I am asking about this question stackoverflow.com/questions/24265292/…. –  imp Jun 18 at 5:41
1 
The %1 %2 etc. in the reg file are the argument(s) for your app. So if you do YourApp.exe "your argument" so %1 == "your argument" –  Erwinus Jun 18 at 5:45 
   
please see question, I added image of registry. I am asking about url that I have to type in explorer along with filename as argument. –  imp Jun 18 at 5:52

Here's a list of the registered URI schemes. Each one has an RFC - a document defining it, which is almost a standard. The RFC tells the developers of new applications (such as browsers, ftp clients, etc.) what they need to support. If you need a new base-level protocol, you can use an unregistered one. The other answers tell you how. Please keep in mind you can do lots of things with the existing protocols, thus gaining their existing implementations.

share|improve this answer
3 
Notwithstanding the technical details of how to make a protocol work in Windows - this is the most important answer. You shouldn't create a new URI scheme unless it's registered with IETF, or using an experimental namespace (like an X- prefix) –  Alnitak Dec 23 '08 at 16:09

For most Microsoft products (Internet Explorer, Office, "open file" dialogs etc) you can register an application to be run when URI with appropriate prefix is opened. This is a part of more commonexplanation - how to implement your own protocol.

For Mozilla the explanation is here, Java - here.

share|improve this answer

The first section is called a protocol and yes you can register your own. On Windows (where I'm assuming you're doing this given the C# tag - sorry Mono fans), it's done via the registry.

share|improve this answer

A Protocol?

I found this, it appears to be a local setting for a computer...

http://kb.mozillazine.org/Register_protocol

share|improve this answer

It's called the protocol. The only thing that prevents you from making your own protocol is you have to:

  1. Write a browser or user agent of some kinds that understands that protocol, both in its URL form and in the actual data format
  2. Write a server that understands that protocol
  3. Preferably, have a specification for the protocol so that browser and server can continue to work together.

Windows makes #1 really easy, an in many cases this is all you actually need. Viz:

Registering an Application to a URL Protocol

share|improve this answer

You don't really have to do any registering as such. I've seen many programs, like emule, create their own protocol specificier (that's what I think it's called). After that, you basically just have to set some values in the registry as to what program handles that protocol. I'm not sure if there's any official registry of protocol specifiers. There isn't really much to stop you from creating your own protocol specifier for your own application if you want people to open your app from their browser.

share|improve this answer
2 
-1: misguiding, uses inaccurate nomenclature and does not provide any real value –  Marek Nov 9 '10 at 11:44

protected by Daniel A. White Sep 1 '11 at 22:34

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site. 

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged  or ask your own question.

'Protocol > url protocol' 카테고리의 다른 글

java protocol  (0) 2014.08.10
URL Protocol로 프로그램 실행 방법  (0) 2014.08.10
SSH URL Protocol 등록하여 PuTTY 사용하기  (0) 2014.08.10
Posted by wrnly
Protocol/url protocol2014. 8. 10. 02:32

import java.net.*;
import java.io.*;

public class NET1 
{
 URL url;
 InputStream is;
 BufferedInputStream bis; 
 BufferedOutputStream bos;
 FileOutputStream fos;

 public NET1()
 {
  String spec = "http://www.hanmail.net:80/index.html";
//  String spec = "http://www.hanmail000000000000000000000.net:80/index.html";// 실제 존재하지 않는 사이트
//  String spec = "www.hanmail.net:80/index.html"; //MalformedURLException이 발생한다. 
//  String spec = "http://image.hanmail.net/hanmail/top/2005f_top/daum.gif";
//  String spec = "http://news.naver.com/hotissue/main.php?hotissue_id=1173&nt=20060426152019";
  try {
   url = new URL(spec); 
      pln("url객체 생성 성공 : " + url);
   //url객체 생성 성공 : http://www.hanmail.net:80/index.html
  }catch (MalformedURLException me){ //정해진 폼에 어긋났을때 발생
            pln("예외 : " + me);
  } 
  
  String protocol = url.getProtocol();
  pln("protocol : " + protocol);
  //protocol : http

  String host = url.getHost();
  pln("host : " + host);
  //host : www.hanmail.net

  int port = url.getPort();
  pln("post : " + port);
  //post : 80

  String file = url.getFile();
  pln("file : "+ file);
  //file : /index.html

  String path = url.getPath();
  pln("path : "+path);
  //path : /index.html

  String query = url.getQuery();
  pln("query : "+query);
  //query : null
  //query : hotissue_id=1173&nt=20060426152019
  // 서버쪽으로 데이터를 넘길때 ?하위를 잘라 올때

  /*  
  try{
   is = url.openStream(); // InputStream과 outputStream은 모든 데이터를 받아온다. 
   bis = new BufferedInputStream(is);
   byte b[] = new byte[512];
   int i=0;
   while((i=bis.read(b)) != -1){
    System.out.write(b, 0, i);

   }
  }catch (IOException ie)
  {
   pln("입력 스트림 객체 생성 실패 : "+ie);
  }
  // 모든 데이터를 보여준다. 
  /*
  결과 :: 
  <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html lang="ko">
  <head><meta http-equiv="Content-Type" content="text/html; charset=euc-kr"><meta.............
  */


  try{
   is = url.openStream(); // InputStream과 outputStream은 모든 데이터를 받아온다.  
   // 실제 존재하지 않는 사이트에 대해서 오류가 발생하게 되는 부분... 
   bis = new BufferedInputStream(is);
   int index = path.lastIndexOf("/"); // / 위치
   String fName = path.substring(index+1); // index+1까지 자른다. 
   System.out.println("fName : "+fName);
   //fName : index.html

   fos = new FileOutputStream(fName);
   bos = new BufferedOutputStream(fos);
   byte b[] = new byte[512];
   int i=0;
   while((i=bis.read(b)) != -1){
    bos.write(b, 0, i);
    bos.flush();
   }
   System.out.println(fName + "을 다운로드 성공");
  }catch (IOException ie)
  {
   pln("입력 스트림 객체 생성 실패 : "+ie);
  }
  // 모든 데이터를 보여준다. 
  /*
  결과 :: 
  index.html을 다운로드 성공
  ==> index.html(fName과 동일한 파일)이라는 파일 생성 
  */
  finally
  {
            try
            {
             bis.close();
    is.close();
    bos.close();
    fos.close();
            }
            catch (IOException ie){}
  }
  // close() 실행

//  openConnection // url Connection을 리턴한다. 
 }

    public void pln(String str){
  System.out.println(str);
 }

 public static void main(String[] args) {
  new NET1();
 }
}
/*
url객체 생성 성공 : http://www.hanmail.net:80/index.html
protocol : http
host : www.hanmail.net
post : 80
file : /index.html
path : /index.html
query : null
*/

/*
url객체 생성 성공 : http://news.naver.com/hotissue/main.php?hotissue_id=1173&nt=
20060426152019
protocol : http
host : news.naver.com
post : -1
file : /hotissue/main.php?hotissue_id=1173&nt=20060426152019
path : /hotissue/main.php
query : hotissue_id=1173&nt=20060426152019
*/

/*
url객체 생성 성공 : http://news.naver.com/hotissue/main.php?hotissue_id=1173&nt=
20060426152019
protocol : http
host : news.naver.com
post : -1
file : /hotissue/main.php?hotissue_id=1173&nt=20060426152019
path : /hotissue/main.php
query : hotissue_id=1173&nt=20060426152019
*/

 

Posted by wrnly
Protocol/url protocol2014. 8. 10. 02:15

MS Windows 환경에서의 팁이라 할 수 있다.

URL형태로 프로그램을 실행 시키는 방법에 대한 내용이다.

예로, shellcall 이라는 프로토콜을 정의하겠다.

아래는 예제 URL 형태이다.

 예제 URL : shellcall://charles360.tistory.com/asdfSDF324923409uwjrqwWERWER===

먼저, 실행하고자 하는 프로그램은 설치되어 있어야 하며, 특정 경로에 위치하여야 한다.

 예제 경로와 실행파일 : C:\Program Files\test.exe

그 경로와 실행파일명을 레지스트리에 등록하여야 하는데, 다음과 같이 등록하면 된다.

 Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\shellcall]
@="URL:SHELLCALL Protocol"
"URL Protocol"=""

[HKEY_CLASSES_ROOT\shellcall\shell]

[HKEY_CLASSES_ROOT\shellcall\shell\open]

[HKEY_CLASSES_ROOT\shellcall\shell\open\command]
@="\"C:\\Program Files\\test.exe\" \"%1\""

여기까지 진행하고 익스플로러에 실행하면 아래와 같은 화면이 나온다.

 

 

위의 화면은 아래와 같이 레지스트리에 등록하면 표시되지 않는다.

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\ProtocolExecute\shellcall]
"WarnOnOpen"=dword:00000000 

 추가로, 위의 화면의 아이콘 부분을 표시하기 위해서는 다음과 같이 처리하면 된다. 

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\itmss\DefaultIcon]
@="C:\\Program Files (x86)\\iTunes\\iTunes.exe"

위의 화면은 IE의 프로텍티드 모드로 인해 발생하는 것으로 디지털 서명을 하거나 IE의 프로텍티드 모드를 제거하면 될 것이다. -확인은 해보지 않았음.-

 

 

 

'Protocol > url protocol' 카테고리의 다른 글

how do I create my own URL protocol? (e.g. so://…)  (0) 2014.08.10
java protocol  (0) 2014.08.10
SSH URL Protocol 등록하여 PuTTY 사용하기  (0) 2014.08.10
Posted by wrnly
Protocol/url protocol2014. 8. 10. 01:44


SSH URL Protocol 등록하여 PuTTY 사용하기  maniac tech/tip 

2008/07/31 13:59

복사http://coodog.blog.me/90033646352

전용뷰어 보기

첨부파일 (1)

ssh://your.domain.com/ 과 같이 ssh: 프로토콜을 윈도우즈에 등록하여 인터넷 바로가기 또는 HTML 페이지에서 링크 클릭시 PuTTY에 연결되어 사용할 수 있도록 한다.

 

PuTTY는 커맨드 라인으로 도메인명을 받아야 하므로 ssh://your.domain.com/ 를 인자로 넘길경우 제대로 연결이 되지 않는다. 따라서 URL에서 도메인만 추출하여 PuTTY를 실행시키는 스크립트를 만들어 준다. 파란색으로 표시한 PuTTY의 경로는 자신의 컴퓨터에 설치된 경로로 변경해 준다.

 

run_ssh.js

var ssh = "D:\\bin\\putty.exe";

 

if ( WScript.Arguments.count() < 1 ) {
 WScript.Echo( "Usage: run_ssh.js ssh_url\n\n"

  + "ex) run_ssh.js ssh://your.domain.com" );
} else {
 var host = getHostFromUrl( WScript.Arguments.Item(0) );
 if ( host ) {
  var shell = WScript.CreateObject( "WScript.Shell" );
  shell.Run( '"' + ssh + '" "' + host + '"' );
  shell = null;
 }
}

 

function getHostFromUrl( str ) {
 var m = str.match( /^ssh:\/\/([\w\.\-]*)\/*/i );
 return m ? m[1] : null;
}

 

RegEdit를 사용하거나 레지스트리 등록 파일을 만들어 레지스트리에 SSH 프로토콜을 등록한다. 파란색으로 표시한 run_ssh.js의 경로는 자신의 컴퓨터에 저장된 경로로 변경해 준다.

 

ssh_command.reg

Windows Registry Editor Version 5.00

 

[HKEY_CLASSES_ROOT\ssh]

@="URL:SSH(Secure Shell) Protocol"
"URL Protocol"=""

 

[HKEY_CLASSES_ROOT\ssh\DefaultIcon]
@="D:\\bin\\putty.exe,0"

 

[HKEY_CLASSES_ROOT\ssh\shell]

 

[HKEY_CLASSES_ROOT\ssh\shell\open]

 

[HKEY_CLASSES_ROOT\ssh\shell\open\command]
@="wscript.exe \"D:\\bin\\run_ssh.js\" \"%1\""

인터넷 바로가기와 HTML 페이지를 만들어 테스트를 해 보자.

 

ssh_test.url

[InternetShortcut]
URL=ssh://your.domain.com/

ssh_test.html

<a href="ssh://your.domain.com/">test</a>

인터넷 바로가기를 실행하거나 링크를 클릭해서 PuTTY가 실행되고 호스트로 접속이 되면 성공.

 

 

참고 사이트:

Registering an Application to a URL Protocol

Creating a Custom URL Protocol for SSH in Networking

'Protocol > url protocol' 카테고리의 다른 글

how do I create my own URL protocol? (e.g. so://…)  (0) 2014.08.10
java protocol  (0) 2014.08.10
URL Protocol로 프로그램 실행 방법  (0) 2014.08.10
Posted by wrnly