Re: Suggestions for custom application-layer protocol?

From: David Schwartz (davids_at_webmaster.com)
Date: 05/25/05


Date: Wed, 25 May 2005 13:07:30 -0700


"Mark" <mark_2811nospam@excite.com> wrote in message
news:0N4le.10977$on1.1525@clgrps13...

> Thanks for all the excellent suggestions so far. I'll read through the
> RFCs
> for various Internet application protocols. I've also found some good
> information in Eric S. Raymond's online book "Art of Unix Programming".
> It
> would be nice to be able to use a simple standard protocol of some kind.
> It
> seems strange to have to come up with ways of formatting text fields,
> delimiting messages etc since I'm sure this has been done already many
> times
> before.

    You can take a page from the URL encoding scheme and use a list of
<param_name>=<value> pairs delimited by & signs. Encode all less than signs,
greater than signs, & signs, = signs, percent signs, whitespace, control
characters, and non-ascii characters as '%xy' where x and y are the first
and second hexadecimal digit of the ASCII value.

    So a query might be:

query=get&parameter=uptime<newline>

    And a reply might be:

query=get&parameter=uptime&value=1%20hour,%205%20minutes<newline>

    Specify that each end ignore any parameters they don't understand
(rather than considering it an error), and your protocol is extensible.

    DS



Relevant Pages

  • Re: Suggestions for custom application-layer protocol?
    ... > for various Internet application protocols. ... > would be nice to be able to use a simple standard protocol of some kind. ... and non-ascii characters as '%xy' where x and y are the first ...
    (comp.unix.programmer)
  • RE: VPN PPTP problem
    ... Internet Security and Acceleration Server 2004 Standard ... | Protocol Info ... | Header checksum: 0x7708 ... | Transmission Control Protocol, Src Port: 1619, Dst Port: pptp ...
    (microsoft.public.windows.server.sbs)
  • More info (Re: ppp dialin problems: mgetty and ppp.conf)
    ... connection to the Internet, however, it appears that if I maintain the ... slots with slot compression ... 0x8057 (Internet Protocol V6 Control Protocol) was rejected! ...
    (freebsd-questions)
  • Re: New to ISA
    ... Is it safe to have protocol and content ... > The ports that will open are for the external interface of ISA Server ... > ISA Server 2000 can't use packet filters for NATed clients. ... >> All i want to do is NATing to my internal web servers and internet ...
    (microsoft.public.isaserver)
  • Help Interpreting data from Wireshark
    ... Today while on the Internet I got the following data from p54A05FE2.dip.t-dialin.net on my Wireshark display. ... Protocol Info ... Fragment offset: 0 ... Header checksum: 0x78f0 ...
    (comp.os.linux.security)