Secure Computing Flashcards

1
Q

What is MOM?

A

Attackers must possess:
- Method: skills & tools
- Opportunity: time & access
- Motive

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is threat modelling?

A

The process of identifying all possible threats to a system, exploitable or not

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does threat modelling help us to do?

A
  • Understand the system’s threat profile
  • Facilitate secure design and implementation
  • Guide code reviews and penetration tests
  • Discover vulnerabilities
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How do we characterise systems?

A

All about system components and their interconnections

Using usage scenarios, assumptions & dependencies e.g. data flow diagrams and network models

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is an asset and some examples?

A

What we are trying to protect e.g. sensitive data or system availability

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is an access point and some examples?

A

How we can reach the system and asset e.g. ports or files

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How do we identify threats?

A

Develop a threat profile which can be classified as high or low risk by looking at where/how assets can be reached via access points through components and interconnections

For each asset, we create attack goals for it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What do attack trees show?

A

How an asset can be attacked

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What does the root node of an attack tree represent?

A

The goal of the attack

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What do all other nodes of an attack tree represent?

A

Condition/predicate/action

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is an attack path in an attack tree?

A

The path from a leaf node to the root node

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What do data flow diagrams show?

A

The flow of information between different components of a system, focusing on what data is being transferred, where it’s going and how it’s processed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What do data flow diagrams help us to pinpoint?

A
  • Areas where sensitive data is exposed
  • Areas where improper validation, authentication or encryption might occur
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Where do trust boundaries occur?

A

Any point at which entities with different levels of privilege interact

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How do we find trust boundaries?

A
  1. Identify the different principals
  2. Start from either end of the privilege spectrum e.g. Internet user or system administrator
  3. Add a new trust boundary each time a principal talks to another
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What are entry and exist points in data flow diagrams?

A

Places where control or data cross a trust boundary

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Why are data flow diagrams useful?

A

They delineate the attack surface between principals. Threats tend to cluster around entry/exit points on trust boundaries and often follow data flows. Therefore, we have a systematic way of where to look for threats.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What is STRIDE?

A

Used for classifying threats

Spoofing - masquerading for unauthorised access
Tampering - violating data integrity
Repudiation - denying a performing action
Info Disclosure - violating confidentiality
Denial of Service - preventing a system from working
Elevation of Privilege - gaining special status

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What are the benefits of using STRDE?

A
  • Acts as a useful checklist when considering threats
  • Makes it easier to understand the effects of threats
  • Helps to assign priority to threats
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What is STRIDE-Per-Element?

A

Used in data flow diagrams to constrain STRIDE for particular data flow diagram elements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Are security requirements specified in terms of what must happen or must not happen?

A

Must not happen

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What is a security policy?

A

The set of security requirements

A high-level specification of security properties a system should possess

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What is DREAD?

A

Used for risk assessment

Damage Potential
Reproducibility
Exploitability
Affected Users
Discoverability

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What are some issues with DREAD?

A
  • Highly subjective to use integers
  • Not all dimensions may be useful e.g. why assume discoverability isn’t always 100%
  • All dimensions are weighted equally
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What are mechanisms with security policies?

A

The basic components needed to satisfy a policy e.g. biometric scanning

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

What is a security model?

A

A model which represents a particular policy or set of policies

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

How are objects classified in access control security models?

A

They are labelled based on the perceived impact if the data is compromised

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

How are employees classified in access control security models?

A

They have clearances and are labelled based on the trust that can be placed on the individual

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
29
Q

What is the access control policy?

A

A user can read a document only if their clearance is at least as high as the document’s classification

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
30
Q

What are the two properties of Bell-LaPadula?

A
  1. Simple Security - no read up
  2. *-property - no write down
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
31
Q

How are the properties of Bell-LaPadula enforced?

A

Through Mandatory Access Control

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
32
Q

How do we formalise subjects and objects in access control security models?

A

They are assigned a security label which is a classification level and the categories - (class, category set)

A binary relation is defined, D (dominates), over a set of labels which is a partial order

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
33
Q

What are the three properties of partial orders?

A
  1. Reflexive - every element is related to itself
  2. Antisymmetric - if a dominates b and b dominates a, then a and b are the same
  3. Transitive - if b dominates a and c dominates b, then c dominates a
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
34
Q

What is exec in access control security models?

A

A predicate which takes a subject, and object and an action

<s,o,a> is a member of exec

This states that a subject s can perform action a on object o

It is a formal specification for the behaviour of a reference monitor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
35
Q

What do reference monitors do?

A

They enforce the simple security and *-property properties

Each triple (s, o, a) is checked against the reference monitor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
36
Q

What are the two properties of BIBA Integrity model?

A
  1. Simple security - no read down
  2. *-property - no write up
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

What is the Chinese Wall Model used for?

A

Modelling the constraints of a form of professionals whose partners need to avoid conflicts of interest and/or insider dealing

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
38
Q

What is the basic purpose of the Chinese Wall Model?

A

Once a partner consults for a company of a given type, it cannot consult for another company of the same type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
39
Q

How does the Chinese Wall Model keep track of state?

A

A Boolean 2D matrix C[s,o] which = 1 if s has accessed o, otherwise = 0

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
40
Q

What are the two properties for the Chinese Wall Model?

A
  1. Simple Security - each subject can access objects from at most one company from each type
  2. *-property - write access to s to write to o is only permitted if access is permitted by the simple security rule and if all other object p which s has written to is such that t(o) = t(p) or p is a sanitised object
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
41
Q

What is the basic idea of Resurrecting Duckling?

A

For systems that need secure transient associated - where the security policy is transient

The two systems will need to secure and authenticate, restart (resurrecting) with a clean state (duckling)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
42
Q

What are the two states in Resurrecting Duckling?

A
  1. Imprintable - ready to trust another system
  2. Imprinted - committed to trust system
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
43
Q

What are the two transitions in Resurrecting Duckling?

A
  1. Imprinting - sends some secret key
  2. Death - by an order, by old age or when the transaction has ended
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
44
Q

What two properties do algorithms always consist of?

A
  1. Safety property - you want to prohibit things that can’t happen
  2. Liveness property - what are the good things you want to happen
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
45
Q

Give examples of safety properties

A

E.g. writing in a part of memory you don’t want to write in, at one time at most one process can access one piece of data, in a token ring at most one node holds the token

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
46
Q

Give examples of liveness properties

A

In a token ring, you eventually want every node to hold the token, termination of a program

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
47
Q

Are all security policies enforcable?

A

No

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
48
Q

What kind of information can an EM use?

A

Past events - cannot predict the future and doesn’t know about alternative or all possible executions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
49
Q

What is the safety and liveness property of mutual exclusion - processes accessing critical section?

A

Safety - at most one process can access critical section
Liveness - every requesting process is eventually grated access to critical section

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
50
Q

Is every security policy a property, and why (not)?

A

No because the membership of an execution within the policy may rely on another execution i.e. needs to know more than just the one execution

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
51
Q

What do we know about bad executions and prefixes?

A

If we have a prefix that turns false, it must remain false after

If an execution is bad, then we can find an execution that has already gone bad

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
52
Q

How can we define safety properties?

A

If it is possible that it has a bad prefix

A property is a safety property if, for every execution that is not in the property, there exists a prefix of the execution that is not in the set

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
53
Q

Match safety/liveness property to prefix/suffix

A

Safety property concerns prefixes
Liveness property concerns suffixes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
54
Q

Is access control a safety property?

A

Yes because a bad prefix is when an unauthorised operation is attempted

55
Q

Is availability a safety property?

A

No because the mechanism would be to know what will happen in the future

56
Q

What would the security automata and guarded command be for a security policy of no Send after FileRead

A

(check notes)

57
Q

Can we use time units to enforce a property? If yes, why? If no, why and what do we use instead?

A

No because we cannot control the environment

We use execution steps instead

58
Q

What is the solution for SQL injection?

A

Prepared statements - parameterised and reusable SQL queries

59
Q

What are the different types of attacks on URLs?

A

Phishing - using fake URLs resembling legitimate ones
Homograph attacks - exploiting visually similar characters across different alphabets
Punycode - exploiting the representation of Unicode characters using ASCII
URL obfuscation - techniques to hide the true destination of a URL e.g. long URLs, encoded URLs, shortened URLs and redirects
Directory traversal - accessing other parts of the file system

60
Q

What is a solution to URL attacks?

A

Canonicalisation - convert all user input to it’s simplest form before making any security decisions

61
Q

What are the 4 typical goals of web attacks?

A
  • Tampering with data
  • Information Disclosure
  • DoS
  • Elevation of privilege
62
Q

How are sessions represented and where?

A

A session is represented by a persistent token (session ID)

A session ID is stored client-side and presented to the server

Sessions can have an associated state which can persist locally (cookies, HTML5 web storage) or on the server

63
Q

What are some limitations of HTTPS?

A
  • Can have crypto issues e.g. DROWN attack
  • HSTS forces the use of HTTPS for all connections but still allows an initial insecure request via HTTP so there is a (very small) risk of a MITM attack
  • Misuse of TLS certificates could pose security issues
64
Q

What are open redirects, how could they be used in an attack and what’s a fix?

A

They are when you are forced to authenticate before giving you the page you wanted to visit, that redirect is then stored in the query string and facilitates a redirect afterwards

An attacker could give a redirect to some bad page

A fix would be to validate the redirect parameter

65
Q

What is URL jumping, how could it be used in an attack and what’s the best fix?

A

When applications have an expected flow from page to page

If an attacker could skip a step, that could pose an issue

The best fix is to track the flow is session data stored on the server

66
Q

What’s the best way to manage secure passwords?

A

With a strong hash function (SHA-256 or bigger)

And plenty of random salt (pieces of random data added to a password before it is hashed)

Make the algorithm very slow i.e. iterate many times

Notify users promptly when breached

67
Q

What is the danger associated with session IDs, and how could attackers get them?

A

Compromising the session ID would leave to the attacker impersonating the user

If the session ID is calculated with predictable or weak algorithms, the attacker could guess or calculate it

Could be stolen through attacks to the victim’s computer, XSS or packet sniffing

Could be stolen through exposure by URL rewriting - when session IDs (typically stored as cookies) are rewritten to be included as a query parameter because the browser doesn’t support cookies or they have been visible - therefore it’ll be visible in the browser history and could be cached by web proxies

68
Q

How can sessions be managed securely?

A
  • Generate IDs with a cryptographic PRNG (Pseudo-random number generator)
  • Never reuse IDs
  • Use HTTPS and enable Secure cookie option
  • Establish a maximum session lifetime e.g. 1 or 2 hours
  • Invalidate sessions that have been idle for a while
  • Make it easy to log out and clear the session explicitly
  • Limit session concurrency
  • Minimise the use of the client for storing session state and encrypt anything stored client-side
69
Q

What are malicious XML payloads?

A

Traditional web services exchange messages represented as XML documents - these must be parsed which creates opportunities to exploit weaknesses in the parser implementation

70
Q

What is XSS?

A

A type of injection attack where malicious scripts are injected in otherwise trusted websites

When the victim visits the infected page, the attacker’s code is downloaded to their browser and executes

71
Q

What are the two main types of XSS?

A

Reflected and stored

72
Q

What is reflected XSS?

A

When an application receives data in a HTTP request and includes that data within the immediate response in an unsafe way

When an attacker gets control of a script executed in the victim’s browser, they can technically fully compromise that user

Executed with social engineering

73
Q

What is stored XSS?

A

Relies on some injected JavaScript being stored on the vulnerable server

Targets sites like discussion forums, blogs with comments and shopping sites with reviews

The malicious code can therefore persist for a long time and be seen by may people, and there is no need for social engineering -> big impact

74
Q

What are some countermeasures to XSS?

A
  • Encoding HTML before it is delivered to the browser
  • Rejecting HTML and requiring user-supplied content to be written in something like Markdown
  • Use the HttpOnly attribute flag with cookies to hide them from JavaScript code
75
Q

What is HTML injection?

A

When attackers inject a frame which points back to a server they control

E.g. the framed page would display a message saying the user has been logged out and must resupply credentials

Can happen when the application doesn’t properly handle user supplied data allowing the attacker to provide valid HTML code e.g. via a parameter value

76
Q

What is XSRF/CSRF?

A

Cross-Site Request Forgery

Exploits the fact that your browser sends an authentication token to a server and tricks you into authenticating a request you never intended to take

77
Q

What is a defence of XSRF/CSRF?

A

Generate a random none when the user logs in and store it with the user’s session data

The nonce is then included in pages sent back to the user’s browsers as a hidden form field so will be returned to the server in requests originating from those pages

Then, it can be checked against the value stored in the server for that session

78
Q

What two levels does address resolution happen at?

A
  1. DNS - resolves human-readable domain names into numeric IP addresses needed for routing
  2. ARP (Address Resolution Protocol) - resolves IP addresses into the 48-bit MAC addresses that identify a specific network interface or hardware
79
Q

How can DNS be attacked?

A

Cache Poisoning - an attacker sends forged DNS responses to a DNS resolver, tricking it into caching malicious IP addresses for domain names - therefore redirecting users to malicious websites

Spoofing - the attacker directly intercepts DNS queries and responds with fake answers in real time

MITM Attack - an attacker intercepts DNA queries and replies, altering them to direct traffic to malicious sites

80
Q

How can ARP be attacked?

A

Cache poisoning - an attacker sends fake ARP replies to a victim, associating the attacker’s MAC address with the IP address of a legitimate device allowing MITM and DoS attack

81
Q

Why is remote access with telnet or rlogin bad?

A

All traffic is unencrypted

82
Q

What is banner grabbing?

A

The deliberate use of telnet with non-telnet ports

Gains info about a system or network and their services which are running on open ports as some will sometimes respond with banners leaking information about software vendor, versions etc.

Threatens information disclosure

83
Q

What is the fix to unsecure remote access?

A

SSH - a cryptographically enabled protocol for login, file transfer and TCP connection tunnelling

Traffic is encrypted with a symmetric cipher negotiated between the client and server

84
Q

What are some problems with SSH?

A
  • Complex custom-designed protocol
  • SSH-1 had design flaws and is now considered insecure
  • SSH-2 is superior but has its own issues
85
Q

What is the danger of a MITM attack to remote access?

A

An attacker could steal credentials if they could impersonate a server and may not be noticed if they forward your connection attempt to a real server

86
Q

What is a countermeasure to MITM attacks to remote access?

A

Using SSH to maintain a local store of trusted public keys for previously accessed servers

The user if asked whether they trust a server the first time they connect and the public key is added if they say yes

There still exists a risk but there is a smaller window of opportunity

87
Q

What is SMTP and its dangers?

A

A simple request-response protocol using port 25

There is no authentication allowing easy spoofing

All traffic is sent as ASCII plain text

Banners leak information

Open relays are heavily abused (spam)

88
Q

What are IMAP and POP3 and their dangers?

A

For receiving mail

The username/password are usually sent as plaintext

Using the extensions, the server sends a timestamp and the client sends back the MD5 hash of this and a shared secret

The mail itself is unprotected

89
Q

How can email protocols be secured?

A

Using SSH to tunnel insecure protocols over an encrypted channels - not the best option

Best option - using the extended support for TLS that protocols have now

90
Q

What is opportunistic TLS for securing email protocols?

A

When you continue to use standard ports but add a ‘STARTTLS’ command to the protocols triggering a TLS handshake and upgrades to a secure connection

91
Q

What are some source code QA techniques?

A
  • Code review
  • Checklists
  • Static analysis tools
  • Run-time fault injection
92
Q

What is Whittaker’s model?

A

A framework for classifying and organising software security testing activities based on the types of vulnerabilities they aim to identify

93
Q

What should we combine passwords with to make them more secure?

A
  1. Physical tokens
  2. 2FA
94
Q

What is the revocation problem in using biometrics?

A

The fact that if a database of biometric credentials was comprised - it would be a massive problem since biometrics are irrevocable

The solution is to combine a revocable factor with a biometric factor, hash this and store the hash. If the database is subsequently hacked, we can revoke the hash and change the revocable factor

95
Q

What keys and type of ciphers does public key cryptography use?

A

Public key
Private key
Asymmetric ciphers

96
Q

What are the 4 requirements of public key cryptography?

A
  1. Easy to encrypt given the public key
  2. Easy to decrypt given the private key
  3. Infeasible to determine the private key given the public key
  4. Infeasible to recover the plaintext given the public key and encrypted message
97
Q

What is RSA based on?

A

The extreme difficulty of factoring the product of two very large prime numbers

98
Q

What are the steps of RSA?

A
  1. Select two large prime numbers, p and q
  2. Calculate the product n = pq
  3. Calculate the Euler totient of n, φ(n) = (p-1)(q-1)
    a. Counts the positive integers up to a given integer n that are relatively prime to n
    b. Given integers a and b, a and b are relatively prime if gcd(a, b) = 1
    c. Euler totient of 9 = 6 (1, 2, 4, 5, 7, 8 are all relatively prime to 9)
    d. Select two prime numbers e.g. 3 and 7, product = 21
    e. Euler totient = 12 = (2*6) (1, 2, 3, 4, 5, 8, 10, 11, 13, 16, 17, 19, 20)
  4. Select an integer e such that the greatest common divisor of e and φ(n) is 1
  5. Calculate an integer d such that de mod φ(n) = 1
99
Q

What would the output of RSA be using p = 17 and q = 11?

A
  1. Select two prime numbers: p = 17, q = 11
  2. Calculate product: n = 17 x 11 = 187
  3. Calculate Euler totient: φ(n) = (p-1)(q-1) = 16 x 10 = 160
  4. Choose integer e: e = 7
  5. Determine value of d: 7d mod 160 = 1, 7d = 161, d = 23
100
Q

How can RSA be attacked?

A
  • Brute-force search of all private keys
  • Shared prime - if two key pairs share one prime, it’s easy to recover all three primes
  • e is fixed and too small
101
Q

What is elliptic curve cryptography?

A

Based on the mathematical properties of elliptic curves

Equivalent security to RSA for smaller key sizes - faster than RSA but verifying signatures is slow

102
Q

What are digital signatures?

A

They are used to ensure the authenticity, integrity and non-repudiation of digital data

Uses public key cryptography with the private key kept secret by the signer and the public key shared with other to verify the signature

103
Q

What are the steps in using digital signatures?

A
  1. The signer generates a hash of the data
  2. The hash is encrypted with the private key - creating the digital signatures
  3. The recipient uses the public key to decrypt the signature and retrieve the hash
  4. The recipient independently hashes the original data and compares the two hashes
  5. If the two hashes match, the data is verified as authentic and untampered
104
Q

How can we trust that a public key send from someone was genuinely sent from them?

A

Face-to-face verification or public key certificates

105
Q

What are public key certificates?

A

Certificates in which the public key and owner IS can be transported, signed by a certificate authority

106
Q

What are TLS certificates?

A

Public key certificates that are used for HTTPS

107
Q

What is a firewall?

A

A security guard placed at the point of entry between a private network and the internet which monitors all incoming and outgoing packets

They consist of a set of rules - the decision whether to forward or drop a message depends on the rule that the message satisfies

108
Q

What are 3 challenges when designing firewalls?

A
  1. Consistency - may have conflicting rules
  2. Completeness - the set of rules may be incomplete - difficult to ensure all packets are considered
  3. Compactness - some rules may be redundant
109
Q

What is an FDD?

A

An acyclic and directed graph defined over Fi…Fn where F are the fields e.g. IP address

110
Q

What are the 5 properties of FDDs?

A
  1. Has exactly one root node with no incoming edge, and nodes with no outgoing edges are terminal nodes
  2. Each node in an FDD is labelled with a field whose label is a member of {F1…Fn} if a non-terminal node, or is a member of {a, d} is a terminal node
  3. An edge is labelled with a non-empty set of integers which is a subset of the domain of the field
  4. A directed path from the root to a terminal node is called a decision path - and no two nodes on a decision path have the same label
  5. The set of all outgoing edges of a node satisfy consistency
111
Q

What are the firewall rules for the FDD shown in notes?

112
Q

When are two FDDs equivalent?

A

Iff f.accept = f’.accept and f.discard = f’.discard

113
Q

What are isomorphic nodes?

A
  1. Both v and v’ are terminal nodes with identical labels
  2. Both v and v’ are non-terminal nodes, and there is a 1-1 correspondence between the outgoing edges of v and those of v’ such that every pair of corresponding edges have identical labels and then point to the same node
114
Q

What are the 3 properties to say an FDD is reduced?

A
  1. No node has only one outgoing edge
  2. No two nodes are isomorphic
  3. No two nodes have more than one edge between them
115
Q

What is the algorithm for FDD reduction?

A

Input: FDD fff
Output: Reduced FDD equivalent to fff
Steps: (apply steps 1-3 repeatedly until the FDD cannot be reduced any further)
1. If there is a node v with only one outgoing edge e, where e points to v′:
○ Remove both v and e, and redirect all edges that point to v to point to v′.
2. If two isomorphic nodes v and v′ exist:
○ Remove v′ together with all its outgoing edges, and redirect all edges that point to v′ to point to v.
3. If two edges e and e′ exist that are both between the same pair of nodes:
Remove e′ and change the label of e from I(e) to I(e) ∪ I(e′).

116
Q

Reduce the FDD shown in notes

117
Q

What is the equation for the load of a node in a marked FDD?

118
Q

What is algorithm for marking an FDD?

A

Input: FDD f
Output: Marked FDD f′ with minimal load

Steps:
1. Compute the load of each terminal node v in f as follows: load(v) := 1
2. WHILE (there is a node v whose load has not yet been computed, suppose v has k outgoing edges e1, .., ek, and these edges point to v1, …, vk respectively, and the loads of these k nodes have been computed) DO:
a) Among the k edges of e1,…,ek, choose an edge ej ​with the largest value of (load(ej)-1) * load(vj), and marks edges ej with ‘all’

3. (b) Compute the load of v as follows: load(v) := ∑(i=1 to k) (load(ei) * load(vi))
119
Q

What is the matching predicate?

A

It evaluates only the conditions explicitly set by the rule

So it uses “all” markings

120
Q

What is the resolving predicate?

A

It evaluates all the conditions that reach a terminal node

So it ignores “all” markings - is a generalisation so we want the most restrictive

121
Q

What is the algorithm to create a firewall i.e. create the rules

A

Input: Marked FDD f
Output: Firewall equivalent to f. For each rule r, r.mp and r.rp is computed.

  1. Depth-first traverse f such that for each nonterminal node v, the outgoing edge marked as “all” of v is traversed after all other outgoing edges of v have been traversed.
  2. Whenever a terminal node is encountered, assuming <v1 e1…vk ek v(k+1)> is the decision path where each ei is the most recently traversed outgoing edge of node vi output a rule r together with its matching predicate r.mp and its resolving predicate r.rp as follows:
    a. r is the rule which we create from the path to the decision
    b. r.mp is the predicate of rule r
    r.rp is the predicate which is the same except ignores “all” markings
122
Q

Generate the rules and matching and resolving predicate for the FDD shown in notes

123
Q

What does compaction do to an FDD?

A

Removes redundant rules

124
Q

What is the algorithm for compaction?

A

Input: A firewall <r_1,….,r_m>
Output: An equivalent but more compact firewall
for i = m to 1 do
redundant[i] := 0;
for i = m to 1 do
if there exist a rule rk in the firewall, where i < k ≤ m, such that the following 4 conditions hold:
1. redundant[k] = false
2. ri, rk have the same decisions
3. ri.rp implies rk.mp
4. for every rule rj, where i<j<k, at least one of the 3 conditions hold:
1. redundant[j] = 1
2. ri, rj have the same decision
3. no packet satisfies both ri.rp and rj.mp
then
redundant[i] := 1
else
redundant[i] := 0
for i = m to 1 do
if redundant[i] = 1 then
remove ri from the firewall

OR in plain english:
1. Mark all rules as not redundant
2. For each rule A:
a. Check if there exists a later rule B that does the same as rule A i.e. allows or discards the same kind of traffic. To define this, all four conditions must apply:
i. Rule A hasn’t already been marked as redundant
ii. Both the rules A and B have the same decisions
iii. The resolving predicate of rule A implies the matching predicate of rule B. This means that if rule A applies, then rule B will also apply – since the resolving predicate of A is more general and encompasses the matching predicate of B
iv. There are no intermediate rules C between A and B that conflict with both of them. To define this one of these conditions must apply:
1. Rule C is redundant
2. Rule C has the same decision as rule A (so rule B also)
3. Rule C doesn’t match any packet that could also match rule A – i.e. the rules do not overlap
b. If those conditions apply, then rule A is redundant because rule B does the same thing as A but is more specific. Therefore, we mark rule A as redundant
c. Otherwise, mark as not redundant
3. Loop through all rules and remove those that are redundant

125
Q

Compact the rules shown in notes

126
Q

What does simplification do to an FDD?

A

Basically just splits rules into non-overlapping sub-rules to make the rule set simpler and unambiguous

127
Q

Simplify the rules shown in notes

128
Q

What are the algorithms in order to generate a firewall?

A
  1. Reduction
  2. Marking
  3. Firewall generation (creating rules and predicates)
  4. Compaction
  5. Simplification
129
Q

How do we know we can draw some security automaton for a security policy?

A

The policy is a safety property and the events exist within the systems control

130
Q

What is a security property?

A

A set of executions

131
Q

What is an execution?

A

A sequence of states or events

132
Q

When should we use Bell-LaPadula model?

A

In systems where protecting sensitive information from unauthorised access is critical

133
Q

When should we use BIBA model?

A

In systems where data accuracy, consistency and integrity is more important than confidentiality