-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
161 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{ | ||
"performance": { | ||
"edge": 5, | ||
"lowGraphics": false, | ||
"nodeLabels": 0, | ||
"edgeLabels": 0, | ||
"darkMode": false | ||
}, | ||
"edgeincluded": { | ||
"MemberOf": true, | ||
"HasSession": true, | ||
"AdminTo": true, | ||
"AllExtendedRights": true, | ||
"AddMember": true, | ||
"ForceChangePassword": true, | ||
"GenericAll": true, | ||
"GenericWrite": true, | ||
"Owns": true, | ||
"WriteDacl": true, | ||
"WriteOwner": true, | ||
"CanRDP": true, | ||
"ExecuteDCOM": true, | ||
"AllowedToDelegate": true, | ||
"ReadLAPSPassword": true, | ||
"Contains": true, | ||
"GpLink": true | ||
}, | ||
"databaseInfo": { | ||
"url": "bolt://localhost:7687", | ||
"user": "neo4j", | ||
"password": "blood" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
{ | ||
"queries": [ | ||
{ | ||
"name": "Find DCSyncers", | ||
"queryList": [ | ||
{ | ||
"final": false, | ||
"title": "Select a Domain...", | ||
"query": | ||
"MATCH (n:Domain) RETURN n.name ORDER BY n.name DESC" | ||
}, | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH p=(n1)-[:MemberOf|GetChanges*1..]->(u:Domain {name: {result}}) WITH p,n1 MATCH p2=(n1)-[:MemberOf|GetChangesAll*1..]->(u:Domain {name: {result}}) WITH p,p2 MATCH p3=(n2)-[:MemberOf|GenericAll|AllExtendedRights*1..]->(u:Domain {name: {result}}) RETURN p,p2,p3", | ||
"allowCollapse": true, | ||
"endNode": "{}" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Find logged in Admins", | ||
"queryList": [ | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH p=(a:Computer)-[r:HasSession]->(b:User) WITH a,b,r MATCH p=shortestPath((b)-[:AdminTo|MemberOf*1..]->(a)) RETURN p", | ||
"allowCollapse": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Top Ten Users with Most Sessions", | ||
"queryList": [ | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH (n:User),(m:Computer), (n)<-[r:HasSession]-(m) WHERE NOT n.name STARTS WITH 'ANONYMOUS LOGON' AND NOT n.name='' WITH n, count(r) as rel_count order by rel_count desc LIMIT 10 MATCH p=(m)-[r:HasSession]->(n) RETURN p", | ||
"allowCollapse": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Top Ten Computers with Most Sessions", | ||
"queryList": [ | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH (n:User),(m:Computer), (n)<-[r:HasSession]-(m) WHERE NOT n.name STARTS WITH 'ANONYMOUS LOGON' AND NOT n.name='' WITH m, count(r) as rel_count order by rel_count desc LIMIT 10 MATCH p=(m)-[r:HasSession]->(n) RETURN n,r,m", | ||
"allowCollapse": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Top Ten Users with Most Local Admin Rights", | ||
"queryList": [ | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH (n:User),(m:Computer), (n)-[r:AdminTo]->(m) WHERE NOT n.name STARTS WITH 'ANONYMOUS LOGON' AND NOT n.name='' WITH n, count(r) as rel_count order by rel_count desc LIMIT 10 MATCH p=(m)<-[r:AdminTo]-(n) RETURN p", | ||
"allowCollapse": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Top Ten Computers with Most Admins", | ||
"queryList": [ | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH (n:User),(m:Computer), (n)-[r:AdminTo]->(m) WHERE NOT n.name STARTS WITH 'ANONYMOUS LOGON' AND NOT n.name='' WITH m, count(r) as rel_count order by rel_count desc LIMIT 10 MATCH p=(m)<-[r:AdminTo]-(n) RETURN p", | ||
"allowCollapse": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Shortest Path from SPN User", | ||
"queryList": [ | ||
{ | ||
"final": false, | ||
"title": "Select a domain...", | ||
"query": | ||
"MATCH (n:Domain) RETURN n.name ORDER BY n.name DESC" | ||
}, | ||
{ | ||
"final": false, | ||
"title": "Select a user", | ||
"query": | ||
"MATCH (n:User) WHERE n.domain={result} AND n.HasSPN=true RETURN n.name, n.PwdLastSet ORDER BY n.PwdLastSet ASC" | ||
}, | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH n=shortestPath((a:User {name:{result}})-[r:MemberOf|AdminTo|HasSession|Contains|GpLink|Owns|DCSync|AllExtendedRights|ForceChangePassword|GenericAll|GenericWrite|WriteDacl|WriteOwner*1..]->(b:Computer)) RETURN n", | ||
"startNode": "{}", | ||
"allowCollapse": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Shortest Paths to Domain Admins from SPN Users", | ||
"queryList": [ | ||
{ | ||
"final": false, | ||
"title": "Select a Domain Admin group...", | ||
"query": | ||
"MATCH (n:Group) WHERE n.name =~ {name} RETURN n.name ORDER BY n.name DESC", | ||
"props": { | ||
"name": "(?i).*DOMAIN ADMINS.*" | ||
} | ||
}, | ||
{ | ||
"final": true, | ||
"query": | ||
"MATCH (n:User),(m:Group {name:{result}}),p=shortestPath((n)-[r:MemberOf|AdminTo|HasSession|Contains|GpLink|Owns|DCSync|AllExtendedRights|ForceChangePassword|GenericAll|GenericWrite|WriteDacl|WriteOwner*1..]->(m)) WHERE n.HasSPN=true RETURN p", | ||
"allowCollapse": true, | ||
"endNode": "{}" | ||
} | ||
] | ||
} | ||
] | ||
} |