#unix

243 posts · Last used 9h

Replying to
Advanced Programming in the #UNIX Environment Week 7: Reentrant and Interrupted Functions With this video lecture, we will conclude our coverage of Unix signals, by looking at what happens when we call unsafe functions from within the signal handler as well as what happens when we are interrupted while blocking on certain I/O.

Advanced Programming in the UNIX Environment: Week 07, Segment 5 - Reentrant & interrupted functions

4
3
4
0
Replying to
Advanced Programming in the #UNIX Environment Week 8: Interprocess Communications Intro In this short video lecture, we begin our discussion of Interprocess Communication (IPC). We provide a quick overview of the different properties of IPC mechanisms as well as which mechanisms we will cover in future videos.

Advanced Programming in the UNIX Environment: Week 08, Segment 1 - Interprocess Communication Intro

7
2
3
0
Replying to
Advanced Programming in the #UNIX Environment Week 8: System V IPC In this video lecture, we cover traditional System V IPC: semaphores, shared memory, and message queues (with a quick look at the POSIX message queues implementation). We can then translate those concepts to modern, distributed "message-oriented middleware" such as Apache Kafka, Amazon SQS, or Redis.

Advanced Programming in the UNIX Environment: Week 08, Segment 2 - System V IPC

5
1
4
0
Replying to
Advanced Programming in the #UNIX Environment Week 8: Pipes and FIFOs With this video lecture, we continue our discussion of Interprocess Communication and dive into two of the oldest and most ubiquitous forms of Unix IPC: pipes and FIFOs. We also discuss popen(3) and the dangers of shelling out to unverified commands, a persistent cause of vulnerabilities in any number of tech stacks. (shquote(3) can help.)

Advanced Programming in the UNIX Environment: Week 08, Segment 3 - Pipes and FIFOs

3
1
3
0
Replying to
Whew! I just finished porting 2,852 lines of PDP-11 assembly to C by hand over the past week! This is for form/fed, a form letter editor and generator with template substitutions, introduced in 1971. It's the largest UNIX utility that was never ported to C, and has since been forgotten. 1/6 #unix #retrocomputing #vintagecomputing #reverseengineering
79
19
29
0
Replying to
Most notably, the oldest list of UNIX licensees was produced from a form letter database. Ken Thompson used form/fed to simplify mailing to early users: rather than hand- or typewriting messages, this fancy tool would substitute each recipient and the date. In 1975, when UNIX News was starting up, he used this form letter database to dump the list of contacts that served as the initial subscriber list. The circumstances of the UNIX V4 tape found at the University of Utah are still somewhat unclear, as it was apparently not used for research and only sparse traces of its acquisition survived. But some letters to Martin Newell are in that form letter database and I hope to recover more information through forensic analysis. 2/6 #unix #retrocomputing #vintagecomputing
25
18
2
0
Replying to
You've heard of Y2K and the 2038 problem, but what about the 1975 problem? The UNIX form letter generator converts the current date to a string, but it only handles 1974. Why isn't it more general? Well, the form utility was written around 1971 when UNIX used a different unit for time, jiffies (60ths of a second) since the current year instead of seconds since 1970. This 60× precision caused times to overflow a signed 32-bit integer every 13.6 months, so the epoch was bumped yearly. This yearly ritual of modifying the kernel meant it wasn't worth generalizing to support any year. An earlier version of form uses jiffies since a 1972 epoch. The version from UNIX V4–V6 does the bare minimum to update it to the new system of seconds since 1970, while keeping the yearly overflow. #unix #retrocomputing #vintagecomputing
57
6
39
0