Hacker News new | past | comments | ask | show | jobs | submit login
Fun with Kermit and ZMODEM over SSH (cambus.net)
151 points by fcambus on April 25, 2023 | hide | past | favorite | 107 comments



Hello! Thank you for starting me up! I'm the Kermit protocol and I'm happy to hel... wait, you want to transfer what file? What the hell is a gigabyte? Well, man, OK, you're the user so you know best, but man, this is going to take like, days man, settle in, here we gooo

ooooooo whooooooo OOOOOOOOO AAAAAAAAAAAAAAA !!!!!!!!!!1!! qcjqrjrcorRC!!!

WHAT THE HECK WAS THAT? Did I just do megabytes per second? Holy shit. Am I high or something? What is this hardware? What is going on here?

No... wait... is that the end? Am I done here? No! No, I want to transfer more! More! Megabytes per second! Gigabytes per second! I can see it now, I want it, I want more, please, let's transfer another file, come on man, I want to ride again, please ple

    EXECUTION COMPLETED
    $


My Commodore 64 has a USB interface nowadays (and a few replaced caps). Originally it only had a tape "drive" ie cassette. After a few years we got a 1541 floppy disc unit. Tick, tick tick, whiirrrrrrrr (think: trilled r on speed), fut (etc). Instead of 10-15 mins to load a game it loaded in a fair few seconds. Bear in mind that the 64 refers to 64 kilobytes.

  $ ls -lh /usr/bin/cp
  -rwxr-xr-x 1 root root 123K Apr  3 19:00 /usr/bin/cp
The copy command on this laptop is 123Kb! ls is 135K. Elite on the C-64 has filled 3D polygonal space ships, space stations and stuff, a whopper of a galaxy and a HUD that gives you an excellent idea of what is where in 3D. You get a trading system and ship upgrades etc. Oh and music - The Blue Danube should play when one is docking with a space station. Obviously you'll need a driver for the joystick and keyboard too. You don't get the whole 64Kb to play with either - a fair bit of that is used by the system itself.

Before the C64 I used a ZX81 and before that a ZX80 - they had roughly 1 kilobyte of RAM. The ZX81 had a RAM pack upgrade which added 16Kb. It was a bit wobbly and required a strip of Bluetac to stop it crashing the computer when nudged. An uncle of mine calls "bloody luxury" on that - he learned programming with punched cards - probably ForTran.

This laptop's kernel is 12M and initramfs is 14M and a fallback image of 70M. Add to that a microcode image (7M).

You'll be glad to hear that Kermit weighs in at a svelte 26K (I've just installed it from the Arch AUR)


It's not that the programs are getting bigger. It's just that the bytes are getting smaller.


A byte just doesn’t go as far these days as it used to.


Elite on the C64 did not have filled polygons. It had hidden line removal. Still impressive.

Funny part about Elite is that they supposedly limited the number of galaxies to maintain the illusion that it was manually created instead of built at runtime using a pseudo random number generator with a preselected seed.


"Elite on the C64 did not have filled polygons."

You are correct - I was conflating it with the later PC effort. When you get to my age (etc).

Sadly, nowadays the plain text of the legalese bollocks that you don't even realise you've signed up to is larger than entire games of yesteryear.


What's in that initrd. Surely busybox doesn't take up 14M.


I've just discovered zstd! The cpio archive is 34M.

Busybox is 521K and udevadm is 572K. ext4.ko is 2.4M and libsystemd-shared-253.3-3.so is 3.5M. usr/lib has quite a lot of file in it eg libc.so.6 at 1.9M.


just the "cp --help" is around 5k (uncompressed)


Thanks for the laugh (but also kind of serious) - reminds me of https://xkcd.com/2221/ (what a fast floppy drive you have!)


A few decades from now we’ll start seeing interactive AIs on emulated platforms asking about president Jon Stewart and other 2030s trivia.


Now I'm wondering if there's ever been emulated software that crashed because it tried to calculate a data transfer rate, but the emulator transferred the data faster than the delta in the time measuring in the emulated machine, so it divided by zero.


The original Macintosh ROM does some floppy drive calibration routines on startup to measure jitter in the spin rate. A common source of errors when writing a Macintosh emulator is emulating a "perfect" floppy drive. If the spin rate jitter is zero, the ROM attempts to a divide by zero and crashes.


There's a bug like this in all versions of Windows 95, the original release of Windows 98, and all of the Nashville/Memphis beta releases in between: https://web.archive.org/web/20030819124031/https://support.m...

“The timing calibration code in the Network Driver Interface Specification (NDIS) driver causes a divide by zero if the CPU runs at 2.2 GHz or faster. This problem does not occur with CPUs that run at 2.1 GHz or slower.”

It was patched for Windows 98 (312108USA8.EXE), but '95 was left without an official fix due to its age: http://lonecrusader.x10host.com/fix95cpu.html


Well, certainly a lot of people running older software have had the joy of their disk size being larger than the software can handle. There's plenty of software that expects the disk size in bytes to fit into an signed or unsigned 32-bit int.

I also don't know about data transfer rates but if you want to emulate the really old stuff in DOSBox, you'll need to carefully examine pages like https://www.dosbox.com/wiki/Performance because there are plenty of games that do a divide-by-zero crash when they're trying to time the CPU for running at the desired speed.


Emulated or not, old Turbo Pascal programs would crash on any computer faster than about 200MHz. The initialization code for the CRT module would try to calibrate timing for the Delay function and the division would overflow if the processor was too fast. See https://retrocomputing.stackexchange.com/questions/12111/


Not emulated as such, but I seem to remember certain old computers having problems with compact flash adapters replacing the hard drive because they were too fast.


How I contributed to Emacs

Once when I should've been in college still, I was using the Telix terminal program on a 286 with a 2400MNP5 modem. Now Telix had a really awesome scripting language that could do all sorts of terminal magic, but that's a story for another day.

My connection to the Internet was 8-bit clean, and at the time I was an avid Emacs user/evangelist. (Since then, I have seen the light of vim's face and have never turned away.)

I saw that Emacs included a mapping file for mskermit to generate ESC sequences for Alt+Keypress, and I figured out that if I mapped each scancode for Alt+Keypress to the appropriate 8-bit code, it would convert my Alt key into a Meta buckybit, perfect for Emacs usage!

So I painstakingly mapped out each scancode and transcribed it into the ms-kermit configuration, and before long I was Emacsing in all its 8-bit-meta-glory.

I figured it would be useful to other Emacs users, and so I sent the file upstream. Lo and behold, it was incorporated into the standard Emacs distribution, and it stayed that way for a long, long time.

Unfortunately, since I had never formally assigned copyright or done whatever legal bit needs to be done to GPL the code, TPTB did an audit of the Emacs distro and culled any code that did not have solid legal footing. At that point, ms-kermit was really obsolete anyway, so I suppose it's all for the best!


My only source of internet in undergrad was dialing into my university's modem pool and getting a shell on the main server (a DEC Alpha running OSF/1). Browsing the web was done through lynx.

That worked fine but every now and then, a site would have some inline image that I'd want to see, so I'd view source to get the img URL and then download that to /tmp and transfer the file to my local machine via zmodem. Usually, it wouldn't be worth the effort. I'd also download mp3s off IRC via DCC and queue up a bunch of data for zmodem to transfer overnight or when I was in class. I really appreciated those bytes back then. Now, not so much.


This reminded me that I used to view images over my dialup connection directly in the terminal by catting the image to pbmtoascii and making my terminal font 1 pixel high. It wasn't exactly pretty but it worked.


LOL!! I thought I was the only person who did this. Back in the mid-90's I did the same thing. One day I was feeling a bit randy and decided to visit a certain centerfold magazine website and download some images that way.


One summer, I had access to a local university's Ultrix machine (on 4.2 BSD) via dialup. The connection was 7E1, so Zmodem was out.

But I could uuencode into a big buffer on my terminal program and uudecode locally.


You might have been interested in SLiRP[0] at the time.

[0] https://en.wikipedia.org/wiki/Slirp


The article mentions 'Terminate'. That software was a joy to use.

https://web.archive.org/web/19980627010642/http://www.termin...


Checking up on other old favorites such as BitchX/irssi and slrn, I found they're still being developed:

slrn --- NNTP/spool-based Usenet newsreader last updated: 2023-03-18T04:31:51 [UTC] repository: git://git.jedsoft.org/git/slrn.git tarfile: slrn-pre1.0.4-9.tar.gz ( size: 1563860 bytes; md5: f193d983e104a82ef4fd70b1037f8b60 ) github: https://github.com/jedsoft/slrn

https://github.com/BitchX/BitchX1.3

https://irssi.org/2023/03/31/irssi-1.4.4-released/


I'm using irssi right now! There are still active irc communities.


IRC is still alive. I have irssi on a monitor on the side all the time, both for friends and work.

IRC is not as big as it used to be, but at its highest it was mainstream even for computer illiterates.


I still use slrn. In the old days, I used tin! Also, I use mutt for one of my old email accounts (used to use elm...)


I use SLRN daily.


Yeah, Terminate was a big step up from Telix. Wow that takes me back.


I used both of those, as well as ProComm Plus (PCPLUS.EXE). Thanks for the trip down memory lane!!!


I used all those as well. But I also learned that many experts on the BBSes use Commo. I'm too young to appreciate complexity of Commo at that time.


Oh wait. There's Telemate as well. My all time favorite.


Commo and TeleMate!! That's right! I think I just found my long lost brother! :-) Thanks again. (And yes, TeleMate was my favorite too. I remember it came on 4 x 1.44MB floppies and had a kick-ass scripting language. It was all about the macros and automation back then!)


Wow. I miss those days. Back when life was simple. I really wish my kids could experience working with TSR dos programs, and being intentional of what you are trying to do with a computer. Every k mattered back then.


The swiss knife of BBSing... it even had a Cost Manager that I used, so my parents won't kill me because of high phone bills.


I even remember its creator’s name: Bo Bendsten. I hope he’s doing okay.


I tried to track him down a few years ago so I could register my (previously pirated) copy of terminate. I figured better late than never. But I couldn’t find him.

I recall that there were some shenanigans with the sale of the company. I think there’s some messages floating around on newsgroups and around the place about it. I found this https://paste.ee/p/Z0ywP


Interesting. Thanks for the link. I remember using a Russian clone called “Terminator” which looked way more polished than Terminate, but don’t know if it’s related to this controversy.

EDIT: Oh! I found it and installed it from https://www.sac.sk/files.php?d=3&l= . Apparently, Terminator isn't a Russian clone like I remembered, but actually the successor to Terminate written by George Collins.


Wow! I had no idea about Terminator! It would be fascinating to hear about what happened from Bo's perspective.

edit: this thread has some more info https://groups.google.com/g/comp.dcom.modems/c/JdOtiDGCV3Y

There's one person in the thread who is skeptical that Bo was in the wrong!


Well, that was a rabbit hole to go in. I see that Bo had made no attempt to explain the situation to his followers over the years which isn't in his favor.


Last year we implemented "ymodem over BLE" for reasons that are complicated and possibly stupid.

It felt familiar but strange and wrong to do such a thing. Worked great though.


I still use these protocols for embedded systems. There is almost always a CLI on a UART, so one should be able to transfer files.

Ymodem is simpler and smaller than Zmodem, but we've used both. I've used Zmodem at 921600 baud, but it needs fairly large buffers (for a UART) to work.

One of the big advantages is that TeraTerm for Windows exists, and supports xyzmodem. It means that I often don't have to write any host-side software for things like firmware update, and more important, don't have to touch Windows.


> I still use these protocols for embedded systems

I have a brand new system sitting here next to me on the bench that uses SLIP framing for packetizing Protobufs :)


A former employer still insists on using Xmodem-1K even though Ymodem is almost the same and provides so many quality of life improvements with the header block. It was endlessly annoying to have to manually tell the receiving end the file size and name when a simple upgrade would obviate the need.


So, on the one hand ...

I have actually used 'sz' and 'rz' in relatively modern times for quick and dirty file transfer and found it very convenient in a very narrow set of use-cases.

However ...

It's a serious violation of the cleanliness and available attack surface involved in a terminal interface and we should be on the lookout for, and reject, similar interfaces and applications.

In order for zmodem to work over the terminal, the terminal program itself needs to know something about the text flowing over the connection and then invoke special, extra routines based on monitoring that textual flow.

This opens up all manner of weird, extra attack surface.

The beauty of the text terminal is that I can, theoretically, cat any file I want to without fear of what it contains. I can open up (perhaps with 'strings' or 'hexedit') any email attachment without fear of the strings that it contains. I can do this because I am using a dumb terminal.

As soon as the terminal is smart - even a little bit - you've got vectors for weird strings doing things you don't want them to.


I have bad news for you. Do you know what (n)curses is for? Its basically a library for those magic strings (and ascii control characters) that run extra routines in the terminal. And every terminal has these routines.


As I see it, the parent is specifically worried about the terminal needing to monitor input and fork a process in response. Control character handling should be pretty robust (or worst-case, a NOP). Curses-based programs read/write specific control characters to move the cursor, etc (really any tty should support control characters).

But they don’t fork a new process… (unless I’m very mistaken).


See xterm manpage, "printerCommand" or urxvt manpage, "print-pipe". They may be triggered remotely by the media copy commands. Good news is, this is supposed to be disabled per default.


btw kde konsole has zmodem support apparently?

pretty sure it won't work over mosh tho


> There is something quite special about seeing ZMODEM transfers reach speeds close to 600 MBit/s. It's hard to explain.

Yep that's 1.5 million times the speed I used to get.


Kermit is still used in the embedded space, on modern platforms specifically for uboot.

zmodem can also be used in embedded spaces to retrieve files if the only interface is a serial port.


This! I still recall using zmodem not that long ago for this exact purpose of sending firmware blobs over just a serial connection.


We have switches purchased in the last few years that use zmodem for firmware upload and recovery.

Annoyingly it still supports a maximum of 115200 baud, even though the serial port on the switch is physically USB-C, so on the one occasion we had a switch brick itself and had to use zmodem "in anger" it took quite a long time to upload the replacement firmware.


Still would love if desktop terminal emulators would implement the zmodem receiver side, so that you can ssh into some host of your choice and just type "sz" to copy arbitrary files of your choice onto your local system.


Just use sshfs, or rclone mount, and use the old

     cp -r 
to get your files. MC can connect to ssh/ftps too, and you can copy files and dirs from pane to pane.


It’s just not the same as having transfers available on the remote command line. I have a program I wrote that maintains a local server with a port forwarded over SSH. Then on the remote side I have a client program that sends a file(s) (or folder) back to my local computer. It can either save the file or open it, depending on the command I ran.

This type of automatic transfer makes it very convenient to generate figures on a server (where the data lives) and then view them locally. It’s a much better workflow than having to use sshfs or scp.

What I wrote is really quite similar to an old transfer program like zmodem with the added feature of auto opening a file if I choose.


Once you mount everything as local with rclone, transferring protocols have no sense, everything should be part of a filesystem. Plan9 did it right, there's no difference between local and remote once you get the grasps of 'bind'.


But if the analysis programs are in a different server or you don’t want to transfer 100s of GB of data to the local machine for processing, you still want to have the ability to selectively transfer individual files.

It doesn’t matter if you mount a remote server locally… unless your data is of a trivial size, you still want to do the processing remotely.

I see this as a theory vs practice difference. In theory having one unified file system is great and the way to go. In practice… there are issues.


screen supports zmodem if you have lrzsz installed. Just put "zmodem catch" into your ~/.screenrc , then ssh while in screen and execute sz/rz on the remote end. screen will automatically recognize the control sequence and prompt with a completed sz/rz command - enter executes and sends/receives the file.



I never thought, I'd read again about ZMODEM and Kermit. To learn programming and dive more into C/C++, I implemented both protocols while writing a Windows application to transfer files from the PC to a HP48 graphics calculator over the serial port in ca. 1999. This app then became the "official" PC link program "HPComm", released under the GPL. Almost 25 years go... :-o

https://hpcomm.sourceforge.net/index-old.html


Kermit was a hidden gem on the HP-48.

Company I was doing work for was looking at handheld solutions for on site data collection. One of the things they were looking at was something from Symbol. Nice unit, but, $2k a pop.

I was out visiting my father who happened to have an HP-48, which I had not seen before.

Fiddling with it I managed to learn quite a bit about its (now legendary) capabilities. But I was quite surprised to learn it had a serial port and support for Kermit.

Returning home, I bought one and quickly prototyped a solution for the company, where they’d upload the data from the calculators each day straight to the HP-9000 via Kermit.

You could buy the HP-48 base model for $100, and they ran forever on AAA batteries. We ended up rolling out the project and they bought a dozen of them.

That was a really fun project. I coded much of the calculator code lying in bed.


Thankfully, ZModem existed. I’d never been able to use Kermit successfully back in the days, always had trouble with it. I even had more success with XModem.


Jumping from Kermit to ZModem was quite a revelation for this Muppets fan. I was so sad to find I'd been needlessly reducing my download speed just by going with the fuzzy green frog, when presented with all of the different download options.


What gets me is that ZModem-Resume had effective continuation of failed transfers _decades_ before HTTP got it right. The early days of the web drove me bonkers, having to start over with a long file that failed in the middle.


I remember using a program...I forget what it was called, but it was popular in the 56K days for resuming HTTP downloads. It would even allow you to provide mirror URLs so you could download from multiple sources at once.

I want to say it was called WinGet, but now there's something else called that, so I can't confirm it.

EDIT: It was called GetRight.


> before HTTP got it right

In the spec, yes. But since servers use Content-Encoding instead of Transfer-Encoding for on-the-fly compression, its unspecified now whether the byte offsets in the resumption refer to the compressed or uncompressed file. Result: Download resumption did not work reliably and got removed from browsers.


You probably didn't have Kermit configured correctly; most of us didn't.

When someone finally showed me how to set the options (which default to reliable-but-godawfully-slow) for much higher speed transmission (bigger segments, sliding windows for ACK, maybe a few other things?), it was entirely comparable to Zmodem.


That's pretty funny. I don't remember ever coming across configs for Kermit or other protocols, just the [K]ermit | [Z]modem -type options on the front end of whatever clients I was trying out.

I wonder why more than one client would default to such comparatively-lame settings for Kermit though.


The whole protocol does.

IIRC you basically have to get a Kermit prompt and issue your commands to the server. Which is easy if you use an actual Kermit client, like Columbia put out (though apparently for the last 12 years it's been an independent project no longer affiliated with the university), but most people just used the internal version that came with their terminal program - with the primary effect being that most people had no idea it was actually a fast, flexible protocol (see the long explanation at http://www.columbia.edu/kermit/misconceptions.html).

The stated reason for this is that it should always default to working, and it's up to you to configure it to work well if your connection is better than rusty barbed wire.


Since I can't edit, I'll reply to myself:

The default of "always work" is amply demonstrated by the fact that Kermit is available for CP/M, and can be compiled on a working CP/M-80 system from .HEX files that you just blast over the serial port. Obviously, due to system constraints, this is not a fully modern Kermit.

But it works. And if you want error checking and reliable file transfer on a Kaypro, it's not a bad way to do it.


There was also short BASIC programs that could be readily keyed in that supported the basic lowest common denominator of the Kermit protocol. The goal being to key that in, and use it to transfer and bootstrap a better version of Kermit.


I’m sure I didn’t. Configuring Kermit was a nightmare in itself. :)


My recent experience reviving an old DOS laptop with a serial port is consistent with this.


Interesting, I used kermet on Coherent to dial into work. Once I started it, work would call be back so I would not have to pay for the session on my phone bill.


At my last job, I worked in the PCI cardholder data environment, and we were very careful to limit egress from our systems in order to make it hard to exfiltrate data in the unlikely event of a breach. I remember thinking, if I were a wily hacker and I managed to pop a shell on one of these hosts, I would not be deterred by network egress roadblocks. I'd figure out a way to get `sz` on to a host and exfiltrate data to my heart's content with ZMODEM like we did back in the day.

Looks like it's still quite possible, I wonder if our network monitoring tools would have noticed gigabytes of data flowing out of the network that way.


> I'd figure out a way to get `sz` on to a host and exfiltrate data to my heart's content with ZMODEM like we did back in the day.

Probably as easy as `cat > sz` and then paste it over the wire? Maybe run through base64 first. Although actually depending on the situation you might be able to just do that directly and not bother with this? Like just as a super simple non-scientific test:

    $ ssh someserver cat /bin/ls > ./test-ls
    $ ssh someserver md5sum /bin/ls ; md5sum ./test-ls
    b3535289b2932e25650074aa6d89bf3c  /bin/ls
    b3535289b2932e25650074aa6d89bf3c  ./test-ls
That looks to work.


A related trick that can be actually useful is tar'ing on one side and untar'ing on the other: https://unix.stackexchange.com/questions/19804/compress-a-di...

scp is miserably slow on transferring lots of small files and this can be wildly faster, plus you get your choice of compression program based on what is on each side of the connection and what the bandwidth vs. CPU is.


In the early days of Unix (before rcp was a given), tar pipelines were a common way of moving ) from one machine to another on the network. It was a little nicer than FTP, not only because it didn't need an admin to set up the FT server, but also because you could transfer the files to any directory that you could cd to and had write access to. (And of course, tar made it easy to send a bunch of files and directories at once, too...)


This was a general idea back then terminal connections were physical. Small BASIC program (Your system does have BASIC, right?) or hex dump could be typed in to create a lowest common denominator bootstrap communication/encoding/decoding tool, which then could be used to transfer more complex program to the system. On DOS systems you could "copy /b COM1 file" (on a physical keyboard) or "copy /b CON file" (inside the terminal connection), then try to send data as is. If it was small enough, the line was clean enough, the settings matched, and the system was fast enough to chew it with one bite, it could work.

Here's an extreme example of such program consisting only of printable (and type-able) characters:

http://www.columbia.edu/kermit/ftp/a/tcomtxt.asm

(Seen on https://retrocomputing.stackexchange.com/questions/5202/tran... )

You can also notice the mention of bootstrap files in Kermit, and look them up.

I've recently seen some better known YouTube user doing exactly the thing we discuss on an old system (even including the consequences of accidental port setting mismatch), but, of course, can't remember the exact video.

Norton Commander, in addition to sharing files over serial or parallel port, was able to “clone” itself to another computer by sending a bootstrap loader the same way, then copying the rest. Hmm, the null modem cable pin connection chart in the readme seems to be a regular one (though without carrier detect pin), but the interlink/laplink cable is shown as 8 bit wide (though the thing should probably work with popular legacy 4 bit crossover):

https://rentry.co/nc50readme


In my DOS days, I used a simple text file that was meant to load into MSDOS' debug program to create a uudecode program. For things like laptops that came with MSDOS, nothing else, and no other way to load things on them. You could use type with a comport I believe to save the code to a txt file and then using debug create an executable binary. Here's one such program: http://www.u.arizona.edu/~shunter/uud.txt

Then I'd use type to save a uuencoded version of something like minicom on the laptop, use this program to uudecode it, and then use minicom to download anything else (Windows 95 install files?) using zmodem.


lrzsz is one of the first packages i install when configuring a new system. being able to send and receive files between remote and local without needing a separate ssh session is such a time saver. it's really fast as well. i do wonder if anyone has developed something more modern to make it even more performant?


I have used bare netcat to transfer files. works well enough when the link is good, when it's not... Well I suspect that is when you dig out better tools.

nc -l 1234 > fname

nc host 1234 < fname


https://www.complete.org/nncp/

It supports flakey networks and it has tons of features.


how do you do that, also through qodem or ?


I still miss sz and rz when I ssh from a computer with no ssh server like nearly every windows box. If I remember right, sz = send a file from the server I'm in back to the client server. rz = receive a file from the client server.

You can accomplish the with a new scp session on the client server, but it's an extra step. I use this as a helper when for building the scp command.

function scppath() { echo $USER@$(hostname).$(dnsdomainname):$(realpath $1) ]


There's a "zssh" project that wraps an SSH session with ZModem handling, but it would be neat to see a tool like that this didn't require sz and rz installed.

[0] https://zssh.sourceforge.net/


I remember having to deal with Kermit on the dialup line to the university. The connection wasn't 8-bit clean and IIRC XON/XOFF wouldn't work either on their modem, so it was very finicky and flaky whenever you wanted to transfer something.

Aren't brains amazing, storing all those ancient unused acronyms for decades?


Here's an ugly script to do zmodem over an SSH connection: https://github.com/ThomasHabets/ssh-scripts

Should work through multiple SSH hops, and not giving the hassle of using scp through those same sets of hops.


While it's nice to use a version of Kermit or Zmodem that has SSH built into it, it's not necessary. The plain vanilla versions from decades ago will work just fine in any terminal connection you establish: Telnet, SSH, rsh, whatever - even 7-bit ASCII...

I used this frequently to move files back in the dialup modem days, after doing an ugly redirect to get the Zmodem binary on the far end, and because of its superior compression, Zmodem was faster than uucp/uucico (when you were lucky enough to have the uucp suite installed and configured, which unlike Kermit and Zmodem, required root privileges...)


I tried to sell the OpenSSH team on implementing inline file transfer with zmodem once, but they were not interested.


If there is one thing I've hankered for more often than not... it's been the ability to send a file over my existing SSH connection.

Why this isn't something that isn't supported out of the box is beyond me. Doesn't SSH have a control channel? Couldn't it support this without text mode hacks?


SSH has both control channels and escape codes. They could add this to the \n~? codes.


Kermit and ZMODEM, now that takes me back. Haven't thought about those protocols for a long time.


This is great! Just make sure you upload something as well to keep your ratio intact.


i wrote implementations of the kermit protocol (and vt100 terminal emulators) for z80 cp/m machines and for the 6502-based BBC micro (both purely in assembler) way back in the mid 1980s. it was fun, and the protocol was really well documented, unlike some others i've had to deal with (i'm looking at you DDE & CORBA). oh, happy times! a bit later i wrote an implementation in C (and a bit of assembler for the interrupt-driven i/o) for the ibm pc.


Project for the future: write an Arduino sketch which will send its own (compressed) source code using one of these protocols over the serial interface.


A telequine?


Man this title takes me way back. Of course, ymodem-g on an HST was faster. But hard to beat the auto-resume feature of zmodem.


zmodem... that brings be back to my BBS days when I had a fido node 2:281/909.4. why do I still know that by heart ? playing glorious BBS door-games over 2400 baud :)


LOL... The good old days of writing modem strings for OS/2.


HS/Link was the pinnacle during my modem days.


Compuserve wants their cool back.


sz and rz! Such good memories.


I came here to say this. I still think rz and sz should be supported everywhere. Even now, I can't tell you how many times I wish I could grab a file straight form the terminal. We lost something when we stopped using zmodem. (and for the record, yes, I do know about all the other things that aren't saving a file direct from the terminal)


On the off-chance that your use-case is "minicom to some Linux serial-console", you might be surprised to learn that minicom has rz/sz support built right into it! Assuming that your remote device has lrzsz installed, you can copy files right through your terminal, exactly like you're describing. It's certainly not the fastest transfer-rate, but it's handy in a pinch.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: