···55#mol-chapter("Introduction")
6677// talk about the standard unix abstractions
88-98In mainstream operating systems, an
109omnicient and all-powerful kernel enforces security policy at runtime.
1110// what am i trying to say here.
···1312requesting party has the authorization to access some resource. This tight
1413coupling of security policy and access mechanisms works well since any access
1514must be done through the kernel, so why not perform security checks
1616-alongside accesses? However,
1515+alongside accesses?
1616+1717+1818+This coupling gets challenged as soon as one tries to decouple access mechanisms
1919+from the kernel, as we see in Twizzler.
2020+Twizzler is a research operating system focused on new programming paradigms
2121+2222+However,
1723the enforcement of security policy starts getting complicated when we try
1818-to separate the access mechanisms from the kernel.
2424+to separate the access mechanisms from the kernel.
19252020-//TODO: explain why this happens?
2121-This problem arises in a certain class of operating systems.
2626+// TODO: maybe give a brief introduction to twizzler?
2727+2828+2929+22303131+//TODO: explain why this happens?
2332== Data-Centric Operating Systems
3333+24342535//TODO: daniel feedback
2636// I would add a paragraph motivating the data-centric approach
···3141 + They provide direct, kernel-free, access to data.
32423343 + They have a notion of pointers that are tied to the data they represent.
4444+4545+By defenition, they require the removal of the kernel from the access path.
4646+This is desirable since it would remove the kernel overhead for data accesses,
4747+resulting in pure performance gains for heavy I/O applications.
34483549// then this paragrapch can focus on why removing the kernel
3650// from the access path is a security probjem
+8-1
3-cap.typ
···5566// define a capability
77Capabilities are the atomic unit of security in Twizzler, acting as tokens of
88+//NOTE: point forward towards security contexts?
89protections granted to a process, allowing it to access some object in the ways
910it describes. Colloquially a capability is defined as permissions and
1011a unique object to which those permissions apply, but in Twizzler we add
···2829//
2930== Signature
3031The signature is what determines the validity of the capability. The
3131-only possible signer of some capability is who ever has permissions to the
3232+only possible signer of some capability is who ever has permissions to read the
3233signing key object, or the kernel itself. The signature is built up of a array with
3334a maximum length and a enum representing what type of cryptographic scheme
3435was used to create it; quite similar to the keys mentioned previously.
···4647but in the context of this thesis it is sufficient to think of them as a region of allowed
4748memory access.
48495050+// interesting! I think this model you describe is more general, if we were to add a SWITCH_CTX permission bit...
5151+// something to think about
5252+4953== Flags
5054Currently, flags in capabilities are used to specify which hashing algorithm to use to form a message to be signed. We allow for multiple algorithms to be used to
5155allow for backward capability when newer, more efficient hashing algorithms are created.
···5559form the message for the signature, but there's plenty of bits left to use.
5660We hope for future work to develop more expressive ways of using capabilities, i.e. Decentralized Information Flow Control, as specified in
57616.1.
6262+6363+//TODO: maybe worth discussing delegations if only to describe how they could be
6464+// extended from capabilities (as a future work ofc)
586559666067#load-bib(read("refs.bib"))
+16-3
4-secctx.typ
···2233#mol-chapter("Security Contexts")
4455-Security Contexts are objects that processes attach to in-order to inherit the
55+Security Contexts are objects that threads attach to in-order to inherit the
66permissions inside the context. The contexts store capabilities, allowing for userspace
77programs to add capabilities to contexts, and kernel space to efficiently search
88-through them to determie whether a process has the permissions to perform a memory access.
88+through them to determine whether a process has the permissions to perform a memory access.
991010== Base
1111···3030this map for lookup while the user interacts with this map to indicate the insertion, removal, or modification of
3131a capability.
32323333+//TODO: talk about the map in memory, and about how its flat, might be worth discussing in the context
3434+// of not storing virtual address pointers.
3535+3336=== Masks
3437Masks act as a restraint on the permissions this context can provide for some targeted object.
3538This allows for more expressive security policy, such as being able to quickly restrict
···60636164The enforcement of security policy in Twizzler happens on page fault when trying to access
6265a new object @twizzler. Upon fault, the kernel inspects the target object and identifies the
6363-default permissnons of that object. Then the kernel checks if the currently active
6666+default permissions of that object. Then the kernel checks if the currently active
6467security context for the accessing thread has either cached or capabilities that provide
6568permissions. If default permissions + the active context permissions arent enough to
6669permit the access, the kernel then checks each of the inactive contexts to see if they
···7679The original Twizzler paper @twizzler, and the following security paper
7780go into more detail about the philosophy behind why enforcement works this way, such as the
7881performance benefits of letting programs access objects directly without kernel involvement, etc.
8282+8383+//TODO: may be worth summarizing a few more bits here
8484+// doesnt have to be super detailed or anything but its better to havea ... thing tie together
8585+// than and a parathere with "etc"
8686+//
8787+// eg. recovering posix semantics and why thats desirable, allowing for
8888+// "contained" threads, ...
8989+//
9090+// basically talk more about stuff from the original twizzler paper about why this style of enforcement
9191+// is good, its fine to benefit
79928093#load-bib(read("refs.bib"))
+12-1
5-results.typ
···3232== Micro Benchmarks
3333Additionally, we have microbenchmarks of core security operations in Twizzler. All
3434benchmarks were run with a Ryzen 5 2600, with Twizzler virtualized in QEMU. Unfortunately
3535+//TODO: do not say they they should be the same :sob:, instead say that finding
3636+// the difference between virtualized performance and actual performance is future work
3537I ran out of time to perform benchmarks on bare metal, but they should be the same, if
3638not more, performant.
37393840=== Kernel
3939-4041There a couple of things we benchmark inside the kernel, including core cryptographic
4142operations like signature generation and verification, as well as the total time it takes
4243to verify a capability.
4444+4545+//TODO: is this with SIMD in kernel? maybe worth discussing this nuance
4646+//
4747+// how many times did you run the experimnt and how were the stats calculated.
4848+//
4949+// could be interesting to compare signature verification cost as the amount of data
5050+// to verify goes up
5151+// my_note: (wouldnt this only be applicable towards delegations though since others are always
5252+// done properly)
5353+//
4354#figure(
4455table(
4556 columns: (auto, auto),
+5-1
6-conclusion.typ
···2233#mol-chapter("Conclusion")
4455+//TODO: So, this is more a summary. Which is good to have here, but
66+// you'll want to have some conclusions -- e.g. What did you learn (e.g. about the
77+// cost of the operations)
58In short we provide a general overview of the critical security
69components for security system in Twizzler, along with
710implementation details and desgin descisions. The evaluation programs show how
···11141215== Future Works
13161717+// TODO: Maybe go into more detail here. There's a number of things that are discussed
1818+// as future work throughout that could use a couple sentences each here.
1419In the future I hope to take the primitives created during my thesis, and apply them towards
1520the implementation of Decentralized Information Flow Control, as described in @flume, into
1621the Twizzler security model. Additionally I would love to see how the current security model
···192420252126== Acknowledgements
2222-2327I couldn't have done the work for this thesis and for Twizzler if it wasn't for the
2428support I've recieved from my advisor Owen Arden and my technical mentor Daniel Bittman! I
2529owe both of you so much, not just for the class credit but also for how much I've learned in