Skip to content

Commit

Permalink
Merge branch 'main' into esc9b-edge-composition
Browse files Browse the repository at this point in the history
  • Loading branch information
rvazarkar authored Feb 8, 2024
2 parents 23ebd1c + 8ecba58 commit 2e84d78
Show file tree
Hide file tree
Showing 12 changed files with 361 additions and 361 deletions.
8 changes: 7 additions & 1 deletion cmd/api/src/test/integration/harnesses.go
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ type InboundControlHarness struct {

func (s *InboundControlHarness) Setup(testCtx *GraphTestContext) {
s.ControlledUser = testCtx.NewActiveDirectoryUser("ControlledUser", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.ControlledGroup = testCtx.NewActiveDirectoryUser("ControlledGroup", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.ControlledGroup = testCtx.NewActiveDirectoryGroup("ControlledGroup", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.GroupA = testCtx.NewActiveDirectoryGroup("GroupA", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.GroupB = testCtx.NewActiveDirectoryGroup("GroupB", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.GroupC = testCtx.NewActiveDirectoryGroup("GroupC", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
Expand All @@ -365,6 +365,7 @@ func (s *InboundControlHarness) Setup(testCtx *GraphTestContext) {

testCtx.NewRelationship(s.GroupA, s.GroupB, ad.MemberOf)
testCtx.NewRelationship(s.UserA, s.GroupB, ad.MemberOf)
testCtx.NewRelationship(s.UserG, s.ControlledGroup, ad.MemberOf)
testCtx.NewRelationship(s.UserG, s.GroupC, ad.MemberOf)
testCtx.NewRelationship(s.UserH, s.GroupD, ad.MemberOf)

Expand Down Expand Up @@ -442,6 +443,7 @@ type SessionHarness struct {
User *graph.Node
ComputerA *graph.Node
ComputerB *graph.Node
ComputerC *graph.Node
GroupA *graph.Node
GroupB *graph.Node
GroupC *graph.Node
Expand All @@ -450,15 +452,19 @@ type SessionHarness struct {
func (s *SessionHarness) Setup(testCtx *GraphTestContext) {
s.ComputerA = testCtx.NewActiveDirectoryComputer("ComputerA", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.ComputerB = testCtx.NewActiveDirectoryComputer("ComputerB", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.ComputerC = testCtx.NewActiveDirectoryComputer("ComputerC", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)

s.User = testCtx.NewActiveDirectoryUser("User", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.GroupA = testCtx.NewActiveDirectoryGroup("GroupA", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.GroupB = testCtx.NewActiveDirectoryGroup("GroupB", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)
s.GroupC = testCtx.NewActiveDirectoryGroup("GroupC", testCtx.Harness.RootADHarness.ActiveDirectoryDomainSID)

testCtx.NewRelationship(s.ComputerA, s.GroupA, ad.MemberOf)
testCtx.NewRelationship(s.ComputerA, s.User, ad.HasSession)
testCtx.NewRelationship(s.ComputerB, s.User, ad.HasSession)
testCtx.NewRelationship(s.User, s.GroupA, ad.MemberOf)
testCtx.NewRelationship(s.User, s.GroupB, ad.MemberOf)
testCtx.NewRelationship(s.ComputerC, s.GroupA, ad.MemberOf)
testCtx.NewRelationship(s.GroupB, s.GroupC, ad.MemberOf)

}
Expand Down
74 changes: 41 additions & 33 deletions cmd/api/src/test/integration/harnesses/adinboundcontrolharness.json
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,8 @@
{
"id": "n12",
"position": {
"x": 75,
"y": 894.3371380482427
"x": 1055.7383287905805,
"y": 894.3371380482428
},
"caption": "User G",
"labels": [],
Expand Down Expand Up @@ -295,90 +295,98 @@
},
{
"id": "n6",
"fromId": "n8",
"toId": "n7",
"type": "GenericWrite",
"style": {},
"properties": {},
"fromId": "n8",
"toId": "n7"
"style": {}
},
{
"id": "n7",
"fromId": "n9",
"toId": "n7",
"type": "GenericWrite",
"style": {},
"properties": {},
"fromId": "n9",
"toId": "n7"
"style": {}
},
{
"id": "n8",
"fromId": "n10",
"toId": "n7",
"type": "GenericWrite",
"style": {},
"properties": {},
"fromId": "n10",
"toId": "n7"
"style": {}
},
{
"id": "n9",
"fromId": "n11",
"toId": "n7",
"type": "GenericWrite",
"style": {},
"properties": {},
"fromId": "n11",
"toId": "n7"
"style": {}
},
{
"id": "n10",
"fromId": "n12",
"toId": "n8",
"type": "MemberOf",
"style": {},
"properties": {},
"fromId": "n12",
"toId": "n8"
"style": {}
},
{
"id": "n11",
"fromId": "n13",
"toId": "n9",
"type": "MemberOf",
"style": {},
"properties": {},
"fromId": "n13",
"toId": "n9"
"style": {}
},
{
"id": "n12",
"fromId": "n8",
"toId": "n7",
"type": "WriteOwner",
"style": {},
"properties": {},
"fromId": "n8",
"toId": "n7"
"style": {}
},
{
"id": "n13",
"fromId": "n8",
"toId": "n7",
"type": "WriteDacl",
"style": {},
"properties": {},
"fromId": "n8",
"toId": "n7"
"style": {}
},
{
"id": "n14",
"fromId": "n9",
"toId": "n7",
"type": "WriteDacl",
"style": {},
"properties": {},
"fromId": "n9",
"toId": "n7"
"style": {}
},
{
"id": "n15",
"fromId": "n9",
"toId": "n7",
"type": "Owns",
"style": {},
"properties": {},
"fromId": "n9",
"toId": "n7"
"style": {}
},
{
"id": "n16",
"fromId": "n9",
"toId": "n7",
"type": "WriteOwner",
"properties": {},
"style": {}
},
{
"id": "n17",
"type": "MemberOf",
"style": {},
"properties": {},
"fromId": "n9",
"fromId": "n12",
"toId": "n7"
}
]
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 2e84d78

Please sign in to comment.