This file is automatically generated from the JSON query files.
Github
Cypher Queries
GitHub extension Cypher queries
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
GitHub extension Cypher queries
MATCH (org:GH_Organization {actions_sha_pinning_required: false})
RETURN org
LIMIT 1000
MATCH p=(:GH_Repository)-[:GH_Contains]->(alert:GH_SecretScanningAlert {state: 'open', validity: 'active'})
RETURN p
LIMIT 1000
MATCH (org:GH_Organization {advanced_security_enabled_for_new_repositories: false})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {actions_allowed_actions: 'all'})
RETURN org
LIMIT 1000
MATCH (app:GH_AppInstallation {repository_selection: 'all'})
RETURN app
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {enforce_admins: false})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {allows_deletions: true})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {allows_force_pushes: true})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {require_code_owner_reviews: false})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {required_pull_request_reviews: false})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {requires_status_checks: false})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {require_last_push_approval: false})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_BranchProtectionRule {dismisses_stale_reviews: false})-[:GH_ProtectedBy]->(:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(actor)-[:GH_BypassPullRequestAllowances]->(rule:GH_BranchProtectionRule)-[:GH_ProtectedBy]->(branch:GH_Branch)
RETURN p
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasRole|GH_HasBaseRole|GH_MemberOf*1..]->(:GH_RepoRole)-[:GH_PushProtectedBranch|GH_BypassBranchProtection]-(r:GH_Repository)
MATCH p1=(:GH_User)-[:GH_BypassPullRequestAllowances|GH_RestrictionsCanPush]->(rule:GH_BranchProtectionRule)-[:GH_ProtectedBy]->(b:GH_Branch)
RETURN p,p1
LIMIT 1000
MATCH (o:GH_Organization)
WHERE o.default_repository_permission <> 'none'
RETURN o
LIMIT 1000
MATCH p1=(extUser)-[:SyncedToGHUser]->(ghUser:GH_User)
MATCH p2=(ghUser)-[:GH_HasRole|GH_HasBaseRole|GH_MemberOf*1..]->(:GH_RepoRole)-[:GH_WriteRepoContents]->(:GH_Repository)-[:GH_CanAssumeIdentity]->(cred:AZFederatedIdentityCredential)
RETURN p1, p2
LIMIT 1000
MATCH (org:GH_Organization {dependabot_alerts_enabled_for_new_repositories: false})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {dependabot_security_updates_enabled_for_new_repositories: false})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {dependency_graph_enabled_for_new_repositories: false})
RETURN org
LIMIT 1000
MATCH p=(:GH_Repository)-[:GH_HasEnvironment]->(env:GH_Environment {can_admins_bypass: true})
RETURN p
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasPersonalAccessToken]->(token:GH_PersonalAccessToken {token_expired: true})
RETURN p
LIMIT 1000
MATCH (ei:GH_ExternalIdentity)
WHERE ei.scim_identity_username = ''
RETURN ei
LIMIT 1000
MATCH p=(src)-[:GH_CanAssumeIdentity]->(cred:AZFederatedIdentityCredential)
RETURN p
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasBaseRole|GH_HasRole|GH_MemberOf*1..3]->(role:GH_OrgRole)
WHERE role.short_name CONTAINS 'all_repo_'
RETURN p
LIMIT 1000
MATCH p=(s)-[]->(d:GH_User)
WHERE s:AZUser
OR s:Okta_User
RETURN p
LIMIT 1000
MATCH (org:GH_Organization {members_can_change_repo_visibility: true})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {members_can_create_pages: true})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {members_can_create_public_repositories: true})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {members_can_delete_repositories: true})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {members_can_fork_private_repositories: true})
RETURN org
LIMIT 1000
MATCH (org:GH_Organization {members_can_invite_outside_collaborators: true})
RETURN org
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasRole]->(:GH_OrgRole {short_name:'owners'})
RETURN p
LIMIT 1000
MATCH (o:GH_Organization)
WHERE o.two_factor_requirement_enabled = false
RETURN o
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasPersonalAccessToken]->(token:GH_PersonalAccessToken {repository_selection: 'all'})
RETURN p
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasPersonalAccessTokenRequest]->(req:GH_PersonalAccessTokenRequest)
RETURN p
LIMIT 1000
MATCH (repo:GH_Repository {visibility: 'private', allow_forking: true})
RETURN repo
LIMIT 1000
MATCH p=(role:GH_OrgRole {type:'custom'})-[r]->(dest)
WHERE dest:GH_Organization
OR dest:GH_OrgRole
RETURN p
LIMIT 1000
MATCH p=()-[:GH_SyncedTo]->(:GH_User)-[:GH_HasRole]->(:GH_OrgRole {short_name:'owners'})
RETURN p
LIMIT 1000
MATCH (repo:GH_Repository {private: false})
RETURN repo
LIMIT 1000
MATCH (org:GH_Organization {secret_scanning_push_protection_enabled_for_new_repositories: false})
RETURN org
LIMIT 1000
MATCH p=(actor)-[:GH_RestrictionsCanPush]->(rule:GH_BranchProtectionRule)-[:GH_ProtectedBy]->(branch:GH_Branch)
RETURN p
LIMIT 1000
MATCH (repo:GH_Repository {secret_scanning: 'disabled'})
RETURN repo
LIMIT 1000
MATCH p1=(:GH_User)-[:GH_HasRole|GH_HasBaseRole|GH_MemberOf*1..]->(:GH_RepoRole)-[:GH_CanCreateBranch]->(repo:GH_Repository)-[:GH_HasSecret]->(s)
WHERE (s:GH_RepoSecret
OR s:GH_OrgSecret)
OPTIONAL MATCH p2=(repo)<-[:GH_CanCreateBranch]-(:GH_User)
OPTIONAL MATCH p3=(repo)<-[:GH_CanCreateBranch]-(:GH_Team)<-[:GH_HasRole|GH_MemberOf|GH_AddMember*1..]-(:GH_User)
RETURN p1, p2, p3
LIMIT 1000
MATCH p=(:GH_Repository)-[:GH_HasWorkflow]->(:GH_Workflow)
RETURN p
LIMIT 1000
MATCH p=(OIP:GH_SamlIdentityProvider)-[:GH_HasExternalIdentity]->(EI:GH_ExternalIdentity)
MATCH p1=(OIP)<-[:GH_HasSamlIdentityProvider]-(:GH_Organization)
MATCH p2=(EI)-[:GH_MapsToUser]->()
RETURN p,p1,p2
LIMIT 1000
MATCH p=(repo:GH_Repository)-[:GH_Contains]->(:GH_SecretScanningAlert {state:'open'})
RETURN p
LIMIT 1000
MATCH (org:GH_Organization {secret_scanning_enabled_for_new_repositories: false})
RETURN org
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasRole|GH_HasBaseRole|GH_MemberOf*1..]->(:GH_RepoRole)-[:GH_WriteRepoContents]->(:GH_Repository)-[:GH_HasSecret]->(s)
WHERE s:GH_RepoSecret
OR s:GH_OrgSecret
RETURN p
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasRole]->(:GH_TeamRole)-[:GH_AddMember]->(team:GH_Team)
MATCH p1=(team)<-[:GH_MemberOf]-(:GH_Team)<-[:GH_AddMember]-(:GH_TeamRole)<-[:GH_HasRole]-(:GH_User)
RETURN p,p1
LIMIT 1000
MATCH p=(:GH_User)-[:GH_HasRole]->(:GH_TeamRole)-[:GH_MemberOf*1..]->(:GH_Team)
RETURN p
LIMIT 1000
MATCH p=(repo:GH_Repository)-[:GH_HasBranch]-(:GH_Branch {protected: false})
RETURN p
LIMIT 1000
MATCH p=(repo:GH_Repository)-[:GH_HasWorkflow]->(:GH_Workflow)
MATCH p1=(repo)-[:GH_HasBranch]->(branch:GH_Branch)
WHERE repo.default_branch = branch.short_name
AND branch.protected = false
RETURN p1
LIMIT 1000
MATCH p=(repo:GH_Repository)-[:GH_HasBranch]-(branch:GH_Branch {protected: false})
WHERE repo.default_branch = branch.short_name
RETURN p
LIMIT 1000
MATCH (org:GH_Organization {web_commit_signoff_required: false})
RETURN org
LIMIT 1000