Operating Systems 2026F Lecture 19

From Soma-notes
Revision as of 16:53, 27 November 2026 by Soma (talk | contribs) (→‎Lecture 19A)

Video

Video from the lectures given on November 26th and 27th, 2026 are now available:

Notes

Lecture 19A

Lecture 19A
-----------

Security, Operating Systems, and AI

Threat models
 - every defense assumes a certain kind of offense

So you need to know what you are protecting yourself from

T1: Paying customers of compute time
 - shared computer
 - each user's usage was billed
 - assumption: everyone was an employee and basically trustworthy

Here's where we get user accounts, user quotas
 - passwords could be very weak, often shared

This is the world of mainframes (1960's)


T2: Users who share a computer
 - everyone is basically trustworthy
 - don't care about usage, will yell at users
   who are using too much

 - copied mainframe user accounts
 - made up really simple file permissions
    - needed to be efficient
 - but didn't bother with the accounting


Where do we start getting REAL operating system security?
 - the military & intelligence organizations
   wanted to use computers to do sensitive operations
 - but they had to share computers because they were expensive
 - worried about malicious users (spies), making sure
   users had limited access

When dealing with classified information, it should be possible for higher classification levels to access lower classification levels, but not vice versa
 - sharing only goes one way

So what do you need to support classified data?
 - some way of labeling data appropriately (fancier permissions)
 - need to also make sure existing access controls cannot be bypassed

Trusted computer base (TCB)
 - the part of the computer system that has to function correctly
   for security properties to hold

So how do you make sure the TCB is secure?
 - make it as small as possible
 - make sure only trustworthy people can change it
   (development and in production)
 - at the highest levels, formal verification
   - prove the TCB is secure (in some model)

In practice, the systems with the most trustworthy TCBs never really got deployed. They existed, but
 - were very expensive
 - very painful to use (poor usability)
 - didn't run the right software

What happened instead is the government, just like everyone else, started using commercial off-the-shelf software (COTS)
 - i.e., Windows

So when did the world start taking computer security seriously
(sort of?)
 - when the web took off!

Heard of the Morris worm? was before the Web, and didn't really change the world of computer security
 - but the web did
 - especially with e-commerce

So how did we start securing the Internet?

One big one was firewalls
 - both for organizations and for individual computers

What is a firewall?
 - mechanism to block certain kinds of network traffic

Operating systems got them built-in, but also were put on networks as appliances

But why did we need firewalls in the first place?
 - because network protocols from the 1980's and early 90's
   assumed the network was trustworthy
   - because they were mostly LANs

Windows (used to?) have a service called WinPopup
 - anyone on the network could pop up a window on your screen

But firewalls were not enough!

We got encryption
 - TLS, ssh

But that wasn't enough either
 - secure communications, but not secure systems

What about malicious code?
 - was a problem from before the Internet

To address malicious code, we developed anti-malware systems
 - "antivirus" initially, but have become more general
 - they just can stop known types of malware

What about when new malware comes out?
 - update the signatures!

But again, not enough. So what did we do?

Patch the vulnerabilities!
 - and we did!

Modern Windows is pretty darn secure...except that regular users can install whatever they want
 - and the operating system will let them change things
   that shouldn't be changed

So what did we really change to make systems more secure?
 - we took away control from users

This has happened in embedded systems and in smartphones (and some tablets)
 - Android, iOS

Both Android and iOS are very UNIX-like underneath
 - Android has Linux, iOS has Mach/XNU from macOS
 - HOWEVER, the security policies are very very different

Regular users can't install any software they want
 - all software must have the right digital signature
 - and the user can't decide which signatures are trustworthy

And how do we make sure only the "right" software runs?
 - trusted computing

Trusted computing is just
 - patch all the bugs
 - implement protections againt certain classes of bugs
   (mainly memory corruption)
 - only run signed code, from boot time onwards
   - check the signatures all the time

So are we secure? Not really!
 - bugs still exist because code is complex and keeps changing
 - and people can still be exploited from within the systems
   we've created

In many ways, secure computing has created solutions that are a bad or worse than the problems they were meant to address
 - end users don't control the devices they own
 - those devices operate without their interests in mind
   (violate privacy routinely)
 - and there's nothing end users can do about it

So where does AI come into this?
 - breaking the old paradigm of patching vulnerabilities
 - not offering any new path forward

How do you deal with adaptive adversaries with arbitrary amount of resources?

First, try to learn from systems that deal with similar problems
 - living systems, i.e. biology

But also embrace what AI brings
 - custom software!

Lecture 19B