I'm wondering about how you plan to implement these chat programs. If they are in "telnet" style, then every character is sent one at a time, depending on you implementation, potentially each one with encryption bloat. There, I certainly see a performance issue, increasing as the connection gets fuzzier. On the other hand, if you are interested in writing something like a messenger where you type the entire message before the other is able to see it, then I see performance benefits over the other. If I'm wrong about such a "graffiti" chat method, then forgive me- you pretty mcuh can't get much faster than that. You will want to send your packets as large as possible to minimize fragmentation. Of course, with chatting, this becomes impractical, so sending a question or a sentence at a time would help you considerably.

Really, it all depends on what you will be using this for. If you use the telnet method and you and your peer are relatively close and the speed is OK, then you're done (you did mention personal use). If, however, if you do find that you need a performance boost, then you should switch to using a messenger-type system.

server: implementing a server (as you say with fork on one user) will give you little if any benefit since you are doing exactly the same thing, only in a different process which is waiting on blocked I/O from the other.

If you send a file vs. one character, then you will certainly notice a simulated bandwidth increase since you are using one encryption function once and sending it perhaps as one or two packets instead of 100 encrypted packets for a sentence.

Since it is only chat, you may want to consider a faster albeit not-so-secure encryption algorithm. Something as simple as XOR or MD5 would certainly do for me since i may be only afraid of packet sniffers. On the other hand, if what you plan on sending through is top secret, then you should certainly use strong encryption.

So, unfortunately, the answer to your questions is: it depends, since it depends on whether or not you see need for such a performance boost when you actually get it running for the first time. I would certainly recommend keeping fragmentation to a minimum, but WUWIWUG (what u want is what u get) and this usually becomes impractical in things such as telnet and chat. Good luck!

AgentM Systems nor Nasca Enterprises nor Bone::Easy nor Macperl is responsible for the comments made by AgentM. Remember, you can build any logical system with NOR.

In reply to Re: Secure Chat Clients by AgentM
in thread Secure Chat Clients by radagast

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.