Docsity

Certification of Program for Secure Information - Assignment | CS 591, Assignments of Computer Science

Partial preview of the text

Download Certification of Program for Secure Information - Assignment | CS 591 and more Assignments Computer Science in PDF only on Docsity!

Information Flow

James Hook

CS 591: Introduction to

Computer Security

Background

  • Denning and Denning, Certification of Programs for Secure Information Flow, CACM 20(7), July 1977
  • Presentation summarized in Bishop Chapter 15

Explicit flows

  • x := 17
  • l := h
  • h := l

Implicit flows

  • How can we write l:=h?
  • Assume l and h are Booleans
    • if h then l:= true else l:= false
    • l := true; if not h then l:= false else skip
    • l := false; while h do l:= true

Type system

  • Judgment forms:
  • Every variable in exp is at or below level |- exp: level
  • Every assignment in C is at or above pc [pc] |- C

Inference Rules

Simple Program

  • Multiplication by repeated addition {a,b >= 0} x := a; r := 0; while (x>0) do x := x -1; r := r + b {r = a*b} Direct Flows: a -> x b -> r Indirect Flow: x -> r

Exercise

  1. h := not l
  2. h := if l then false else true
  3. if l then h := false else h := true
  4. h := true; if l then h := false else skip 5. l := not h 6. l := if h then false else true 7. if h then l := false else l := true 8. l := true; if h then l := false else skip

Information Flow Languages

  • Two serious implementations of information-flow languages - Jif = Java + Information Flow - Andrew Myers and others, Cornell - http://www.cs.cornell.edu/jif/ - FlowCaml - Vincent Simonet - http://cristal.inria.fr/~simonet/soft/flowcaml/

FlowCaml

  • An ML-style language with type inference
  • Windows executable flowcaml gives an interactive type checker - Note: It does not execute the programs, batch compiler flowcamlc compiles them

Anonymous functions and lists

let succ = function x -> x + 1;; let half = function x -> x lsr 1;; let l1 = [1; 2; 3; 4];; let l2 = [x1; x2];;

Defining functions

let rec length = function [] -> 0 | _ :: tl -> 1 + length tl;; let rec mem0 = function [] -> false | hd :: tl -> hd = 0 || mem0 tl ;;

Does it work?

  • In practice it is not broadly adopted
    • Technical issue is the complexity of managing policy
    • I suspect there are social issues as well … the technical issues are not show stoppers

Recall

  • Consider an example (in no particular language)
  • Assume H is high and L is Low H = readHighDatabase() L = readLowUserInput() If f(H,L) then printLow “Success” else printLow “Fail”