20e6bc1a70
* Open redirect vulnerabilty mitigation * Refacted Open Redirect to user configurable and corrected incorrect security variable names. Co-authored-by: danallendds <daniel.allen@friends.dds.mil>
83 lines
1.9 KiB
GraphQL
83 lines
1.9 KiB
GraphQL
# ===============================================
|
|
# SITE
|
|
# ===============================================
|
|
|
|
extend type Query {
|
|
site: SiteQuery
|
|
}
|
|
|
|
extend type Mutation {
|
|
site: SiteMutation
|
|
}
|
|
|
|
# -----------------------------------------------
|
|
# QUERIES
|
|
# -----------------------------------------------
|
|
|
|
type SiteQuery {
|
|
config: SiteConfig @auth(requires: ["manage:system"])
|
|
}
|
|
|
|
# -----------------------------------------------
|
|
# MUTATIONS
|
|
# -----------------------------------------------
|
|
|
|
type SiteMutation {
|
|
updateConfig(
|
|
host: String
|
|
title: String
|
|
description: String
|
|
robots: [String]
|
|
analyticsService: String
|
|
analyticsId: String
|
|
company: String
|
|
contentLicense: String
|
|
logoUrl: String
|
|
featurePageRatings: Boolean
|
|
featurePageComments: Boolean
|
|
featurePersonalWikis: Boolean
|
|
securityOpenRedirect: Boolean
|
|
securityIframe: Boolean
|
|
securityReferrerPolicy: Boolean
|
|
securityTrustProxy: Boolean
|
|
securitySRI: Boolean
|
|
securityHSTS: Boolean
|
|
securityHSTSDuration: Int
|
|
securityCSP: Boolean
|
|
securityCSPDirectives: String
|
|
uploadMaxFileSize: Int
|
|
uploadMaxFiles: Int
|
|
|
|
): DefaultResponse @auth(requires: ["manage:system"])
|
|
}
|
|
|
|
# -----------------------------------------------
|
|
# TYPES
|
|
# -----------------------------------------------
|
|
|
|
type SiteConfig {
|
|
host: String!
|
|
title: String!
|
|
description: String!
|
|
robots: [String]!
|
|
analyticsService: String!
|
|
analyticsId: String!
|
|
company: String!
|
|
contentLicense: String!
|
|
logoUrl: String!
|
|
featurePageRatings: Boolean!
|
|
featurePageComments: Boolean!
|
|
featurePersonalWikis: Boolean!
|
|
securityOpenRedirect: Boolean!
|
|
securityIframe: Boolean!
|
|
securityReferrerPolicy: Boolean!
|
|
securityTrustProxy: Boolean!
|
|
securitySRI: Boolean!
|
|
securityHSTS: Boolean!
|
|
securityHSTSDuration: Int!
|
|
securityCSP: Boolean!
|
|
securityCSPDirectives: String!
|
|
uploadMaxFileSize: Int!
|
|
uploadMaxFiles: Int!
|
|
}
|