←back to thread

Hacker Typer

(hackertyper.net)
270 points rvnx | 6 comments | | HN request time: 0s | source | bottom
Show context
SamWhited ◴[] No.41879318[source]
In school I worked as an intern for a U.S. defense contractor (which I feel rather bad about now, but that's neither here nor there). Every now and then some important general or captain type would show up for a meeting and walk around and look at what all the various labs were doing. When they came to the room where all the interns sat we would all pull up hacker typer and just furiously type away while they were looking in the door.

The important person would always be very impressed and say what a good job we were doing, and our boss who was showing them around (and knew exactly what we were doing) would have to nod and sweat bullets and then would get furious with us afterwards (but it was worth it and we did it every time we knew someone was coming to do an inspection).

replies(3): >>41882189 #>>41882638 #>>41884643 #
syncsynchalt ◴[] No.41882638[source]
Ahh, I used to queue this up on another screen when I needed things to look "busy":

    cat /dev/random | hexdump -C | grep 'ca fe'
Note that it runs a lot faster now than it used to in the 90s.
replies(3): >>41883235 #>>41884214 #>>41888373 #
1. AkshayGenius ◴[] No.41884214[source]
Only tangentially related, but on my MacBook Pro simply running

   cat /dev/random 
causes my terminal to hang and my speakers start emitting a loud buzzing sound until the terminal is force-quit or system is restarted.

I can understand the terminal not being able to handle the amount of data from /dev/random but for the speakers to start emitting sounds as a result of this is certainly very strange. Almost like /dev/random was being piped into /dev/audio or something. Anyone have an explanation?

replies(5): >>41884254 #>>41884412 #>>41884765 #>>41885349 #>>41886723 #
2. Neywiny ◴[] No.41884254[source]
My initial thought is you're getting escape sequences or other signals to trigger the bell/chime. I've never had it crash a terminal but I've never really used a macbook. A common one I'll see in gnome terminal is the terminal printing out some info about itself (I guess there's a way to get some info back from the other side of a link) or changing the title bar.

An easy test would be to have something dump that bell character to the terminal as fast as possible and see if that does it, and also try /dev/zero to check that doesn't.

3. signa11 ◴[] No.41884412[source]
just a guess “visual bell” might fix it perhaps ?
4. thwarted ◴[] No.41884765[source]
This ASCII 7 (C escape "\a"), which when printed emits a bell sound. The exact sound is terminal dependent, and modern terminals won't use the PC speaker but rather play a sound using the audio hardware (which is required on Macs because they don't have a PC speaker). The bell isn't expected to be emitted often and quickly in series, so depending on the capabilities of the terminal program and the audio hardware, it may go haywire trying to play a more complex/longer sound repeatedly or overlapping (like seeming to lock up or slow down as the audio is queued). Your terminal may be configured to "flash" instead of emitting a sound when ASCII 7 is printed -- this may be implemented as rendering the entire window in reverse video for a short duration. A series of discrete bells played quickly may sound like a tone with a rising pitch. Other terminal oddities could occur if ANSI escape sequences. There are many ANSI escape sequences, for changing colors of text, moving the cursor, changing the typeface, or for querying terminal capabilities or customizing the terminal window title bar, that when printed randomly may make the terminal go haywire.

PC Speaker - https://en.wikipedia.org/wiki/PC_speaker

ANSI Escape Sequences - https://en.wikipedia.org/wiki/ANSI_escape_code

5. ◴[] No.41885349[source]
6. 0points ◴[] No.41886723[source]
That's the ascii bell symbol being rendered on your terminal.

See parent's comment, how he piped output from /dev/random into the next command and not to stdout.