@anonymous/

RoundedBisqueReality

Python

No description

fork
loading
Files
  • main.py
  • pytm
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
from pytm.pytm import TM, Boundary, Server, Actor, Datastore, Dataflow, SetOfProcesses

tm = TM("Example Flow Diagram")
tm.description = "This is a sample threat model for the Threat Modeling Workshop."

internet = Boundary(" ")

user = Actor("Actor<br/>(user)")

web = Server("Process")
web.inBoundary = internet

api = Server("Another<br/>Process")
api.inBoundary = internet

db = Datastore("Datastore")
db.inBoundary = internet

another = SetOfProcesses("Multiples<br/>Process")
another.inBoundary = internet

user_to_web = Dataflow(user, web, "HTTPS")
web_to_api = Dataflow(web, api, "HTTP")
api_to_db = Dataflow(api, db, " ")
web_to_another = Dataflow(web, another, "?")

tm.process()