{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "additionalProperties": false,
  "description": "Settings for project analysis by the Application Inspector",
  "id": "https://json.schemastore.org/aiproj-1.9.json",
  "properties": {
    "$schema": {
      "type": "string"
    },
    "Version": {
      "type": "string",
      "enum": [
        "1.0",
        "1.1",
        "1.2",
        "1.3",
        "1.4",
        "1.5",
        "1.6",
        "1.7",
        "1.8",
        "1.9"
      ]
    },
    "BlackBoxSettings": {
      "type": ["object", "null"],
      "title": "Black box and autocheck options",
      "additionalProperties": false,
      "properties": {
        "AdditionalHttpHeaders": {
          "title": "Additional HTTP headers",
          "description": "Dictionary of additional HTTP headers",
          "type": ["array", "null"],
          "items": {
            "type": "object",
            "properties": {
              "Key": {
                "title": "Header",
                "type": "string"
              },
              "Value": {
                "type": "string",
                "title": "value"
              }
            }
          }
        },
        "WhiteListedAddresses": {
          "type": ["array", "null"],
          "title": "Whitelisted addresses",
          "description": "Addresses, that was added in white list",
          "items": {
            "type": "object",
            "properties": {
              "Address": {
                "title": "Address",
                "description": "Address value",
                "type": "string"
              },
              "Format": {
                "type": "string",
                "title": "Address format",
                "description": "Type of address",
                "enum": ["Wildcard", "ExactMatch", "RegExp"]
              }
            }
          }
        },
        "BlackListedAddresses": {
          "type": ["array", "null"],
          "title": "Blacklisted addresses",
          "description": "Addresses, that was added in black list",
          "items": {
            "type": "object",
            "properties": {
              "Address": {
                "title": "Address",
                "description": "Address value",
                "type": "string"
              },
              "Format": {
                "type": "string",
                "title": "Address format",
                "description": "Type of address",
                "enum": ["Wildcard", "ExactMatch", "RegExp"]
              }
            }
          }
        },
        "Authentication": {
          "oneOf": [
            {
              "type": "object",
              "required": ["Cookie", "Type"],
              "properties": {
                "Type": {
                  "enum": ["RawCookie"]
                },
                "Cookie": {
                  "type": "object"
                }
              }
            },
            {
              "type": "object",
              "required": ["Form", "Type"],
              "properties": {
                "Type": {
                  "enum": ["Form"]
                },
                "Form": {
                  "type": "object"
                }
              }
            },
            {
              "type": "object",
              "required": ["Http", "Type"],
              "properties": {
                "Type": {
                  "enum": ["Http"]
                },
                "Http": {
                  "type": "object"
                }
              }
            },
            {
              "type": "object",
              "required": ["Type"],
              "properties": {
                "Type": {
                  "enum": ["None"]
                }
              }
            },
            {
              "type": "null"
            }
          ],
          "type": ["object", "null"],
          "title": "Authentication options",
          "additionalProperties": false,
          "properties": {
            "Cookie": {
              "type": ["object", "null"],
              "title": "Cookie options",
              "description": "Cookie authentication options",
              "required": ["Cookie", "ValidationAddress", "ValidationTemplate"],
              "additionalProperties": false,
              "properties": {
                "Cookie": {
                  "title": "Cookie",
                  "type": "string"
                },
                "ValidationAddress": {
                  "title": "Validation address",
                  "description": "Verification address",
                  "type": "string"
                },
                "ValidationTemplate": {
                  "title": "Validation template",
                  "description": "String to search for",
                  "type": "string"
                }
              }
            },
            "Form": {
              "type": ["object", "null"],
              "title": "Form",
              "description": "Form-based authentication options",
              "additionalProperties": false,
              "properties": {
                "FormDetection": {
                  "type": "string",
                  "title": "Detection",
                  "description": "Type of form authentication detection",
                  "enum": ["Auto", "Manual"]
                },
                "FormAddress": {
                  "title": "Sign-in form URL"
                },
                "FormXPath": {
                  "title": "Sign-in form XPath"
                },
                "Login": {
                  "title": "User"
                },
                "LoginKey": {
                  "title": "User identifier"
                },
                "Password": {
                  "title": "Password"
                },
                "PasswordKey": {
                  "title": "Password identifier"
                },
                "ValidationTemplate": {
                  "title": "Validation template",
                  "description": "String to search for"
                }
              },
              "anyOf": [
                {
                  "properties": {
                    "FormDetection": { "enum": ["Auto"] },
                    "FormAddress": {
                      "type": ["string"]
                    },
                    "FormXPath": {
                      "type": ["null", "string"]
                    },
                    "Login": {
                      "type": "string"
                    },
                    "LoginKey": {
                      "type": ["null", "string"]
                    },
                    "Password": {
                      "type": "string"
                    },
                    "PasswordKey": {
                      "type": ["null", "string"]
                    },
                    "ValidationTemplate": {
                      "type": ["string"]
                    }
                  },
                  "required": [
                    "FormDetection",
                    "Login",
                    "Password",
                    "FormAddress",
                    "ValidationTemplate"
                  ]
                },
                {
                  "properties": {
                    "FormDetection": { "enum": ["Manual"] },
                    "FormAddress": {
                      "type": ["string"]
                    },
                    "FormXPath": {
                      "type": ["string"]
                    },
                    "Login": {
                      "type": "string"
                    },
                    "LoginKey": {
                      "type": ["string"]
                    },
                    "Password": {
                      "type": "string"
                    },
                    "PasswordKey": {
                      "type": ["string"]
                    },
                    "ValidationTemplate": {
                      "type": ["string"]
                    }
                  },
                  "required": [
                    "FormDetection",
                    "Login",
                    "Password",
                    "FormAddress",
                    "ValidationTemplate",
                    "LoginKey",
                    "PasswordKey",
                    "FormXPath"
                  ]
                }
              ]
            },
            "Http": {
              "type": ["object", "null"],
              "title": "Http",
              "description": "HTTP Basic authentication options",
              "additionalProperties": false,
              "required": ["Login", "Password", "ValidationAddress"],
              "properties": {
                "Login": {
                  "title": "User",
                  "type": "string"
                },
                "Password": {
                  "title": "Password",
                  "type": "string"
                },
                "ValidationAddress": {
                  "title": "Validation address",
                  "type": "string"
                }
              }
            },
            "Type": {
              "title": "Type of authentication",
              "type": "string",
              "enum": ["Form", "Http", "RawCookie", "None"]
            }
          }
        },
        "Level": {
          "title": "Search mode",
          "type": "string",
          "enum": ["None", "Fast", "Full", "Normal"]
        },
        "ProxySettings": {
          "type": ["object", "null"],
          "title": "Proxy settings",
          "description": "Proxy server settings",
          "additionalProperties": false,
          "properties": {
            "Enabled": {
              "title": "Enabled",
              "type": "boolean"
            },
            "Host": {
              "title": "Address",
              "type": ["null", "string"]
            },
            "Login": {
              "title": "User",
              "type": ["null", "string"]
            },
            "Password": {
              "title": "Password",
              "type": ["null", "string"]
            },
            "Port": {
              "title": "Port",
              "type": "integer"
            },
            "Type": {
              "title": "Type of proxy",
              "type": "string",
              "enum": ["Http", "Socks4", "Socks5"]
            }
          }
        },
        "RunAutocheckAfterScan": {
          "title": "Run autocheck",
          "description": "Autocheck vulnerabilities after scanning",
          "type": "boolean"
        },
        "ScanScope": {
          "title": "Scan scope",
          "type": "string",
          "enum": ["Domain", "Folder", "Path"]
        },
        "Site": {
          "title": "Website address",
          "type": "string"
        },
        "SslCheck": {
          "title": "Check ssl connection",
          "type": "boolean"
        }
      }
    },
    "DotNetSettings": {
      "type": ["object", "null"],
      "title": ".NET scan options",
      "additionalProperties": false,
      "properties": {
        "ProjectType": {
          "title": "Type of application",
          "type": "string",
          "enum": ["None", "Solution", "WebSite"]
        },
        "SolutionFile": {
          "title": "Solution file",
          "description": "Path to a solution or project",
          "type": ["null", "string"]
        },
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "DownloadDependencies": {
          "title": "Download dependencies",
          "type": ["null", "boolean"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom DotNet kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        }
      }
    },
    "GoSettings": {
      "type": ["object", "null"],
      "title": "Go scan options",
      "additionalProperties": false,
      "properties": {
        "DownloadDependencies": {
          "title": "Download dependencies",
          "type": ["null", "boolean"]
        },
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom Go kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        },
        "DependenciesPath": {
          "title": "Dependencies path",
          "description": "Path that the Go kernel will use as a vendor path",
          "type": ["null", "string"]
        }
      }
    },
    "JavaSettings": {
      "type": ["object", "null"],
      "title": "Java scan options",
      "additionalProperties": false,
      "properties": {
        "Parameters": {
          "title": "JVM start options",
          "type": ["null", "string"]
        },
        "UnpackUserPackages": {
          "title": "Unpack custom JAR files",
          "type": "boolean"
        },
        "UserPackagePrefixes": {
          "title": "Prefixes of custom packages",
          "type": ["null", "string"]
        },
        "Version": {
          "title": "JDK version",
          "type": "string",
          "enum": ["8", "11", "17", "21"]
        },
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "DownloadDependencies": {
          "title": "Download dependencies",
          "type": ["null", "boolean"]
        },
        "DependenciesPath": {
          "title": "Dependencies path",
          "description": "Path that the Java kernel will use as a classPath",
          "type": ["null", "string"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom Java kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        }
      }
    },
    "JavaScriptSettings": {
      "type": ["object", "null"],
      "title": "JavaScript scan options",
      "additionalProperties": false,
      "properties": {
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "UseTaintAnalysis": {
          "title": "Use taint analysis method",
          "type": ["null", "boolean"]
        },
        "UseJsaAnalysis": {
          "title": "Use jsa core for analysis",
          "type": ["null", "boolean"]
        },
        "DownloadDependencies": {
          "title": "Download dependencies",
          "type": ["null", "boolean"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom JavaScript kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        },
        "DependenciesPath": {
          "title": "Dependencies path",
          "description": "Path that the JavaScript kernel will use as a node_modules path",
          "type": ["null", "string"]
        }
      }
    },
    "PhpSettings": {
      "type": ["object", "null"],
      "title": "Php scan options",
      "additionalProperties": false,
      "properties": {
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "DownloadDependencies": {
          "title": "Download dependencies",
          "type": ["null", "boolean"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom Php kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        },
        "DependenciesPath": {
          "title": "Dependencies path",
          "description": "Path that the PHP kernel will use as a dependencies dir",
          "type": ["null", "string"]
        }
      }
    },
    "PmTaintSettings": {
      "type": ["object", "null"],
      "title": "PmTaint scan options",
      "additionalProperties": false,
      "properties": {
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "PMGroups": {
          "title": "List of enabled PM group names",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom PmTaint kernel startup parameters",
          "type": ["null", "string"]
        }
      }
    },
    "PygrepSettings": {
      "type": ["object", "null"],
      "title": "Pygrep scan options",
      "additionalProperties": false,
      "properties": {
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom Pygrep kernel startup parameters",
          "type": ["null", "string"]
        },
        "RulesDirPath": {
          "title": "Custom rules",
          "description": "Path to the custom rules directory",
          "type": ["null", "string"]
        }
      }
    },
    "PythonSettings": {
      "type": ["object", "null"],
      "title": "Python scan options",
      "additionalProperties": false,
      "properties": {
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "DownloadDependencies": {
          "title": "Download dependencies",
          "type": ["null", "boolean"]
        },
        "DependenciesPath": {
          "title": "Dependencies path",
          "description": "Path to venv or path to directory with dependencies if venv was not used to restore them",
          "type": ["null", "string"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom Python kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        }
      }
    },
    "MailingProjectSettings": {
      "type": ["object", "null"],
      "title": "Mail settings",
      "description": "Report mailing options",
      "additionalProperties": false,
      "properties": {
        "Enabled": {
          "title": "Send a report by email after scanning",
          "type": "boolean"
        },
        "MailProfileName": {
          "title": "Email profile name",
          "type": ["null", "string"]
        },
        "EmailRecipients": {
          "title": "List of recipients",
          "type": "array",
          "items": {
            "type": "string",
            "format": "email"
          }
        }
      },
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "Enabled": {
              "enum": [true]
            },
            "MailProfileName": {
              "type": "string",
              "minLength": 1
            },
            "EmailRecipients": {
              "type": "array",
              "minItems": 1,
              "maxItems": 10
            }
          },
          "required": ["Enabled", "MailProfileName", "EmailRecipients"]
        },
        {
          "properties": {
            "Enabled": {
              "enum": [false]
            },
            "MailProfileName": {
              "type": ["null", "string"]
            },
            "EmailRecipients": {
              "type": "array",
              "minItems": 0,
              "maxItems": 10
            }
          },
          "required": ["Enabled"]
        }
      ]
    },
    "RubySettings": {
      "type": ["object", "null"],
      "title": "Ruby scan options",
      "additionalProperties": false,
      "properties": {
        "UsePublicAnalysisMethod": {
          "title": "Use public analysis method",
          "type": ["null", "boolean"]
        },
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom Ruby kernel startup parameters",
          "type": ["null", "string"]
        },
        "DslRulesRelativePath": {
          "title": "Dsl rules",
          "description": "Path to the dsl rules directory",
          "type": ["null", "string"]
        }
      }
    },
    "ScaSettings": {
      "type": ["object", "null"],
      "title": "SCA scan options",
      "additionalProperties": false,
      "properties": {
        "CustomParameters": {
          "title": "Custom parameters",
          "description": "Custom SCA kernel startup parameters",
          "type": ["null", "string"]
        },
        "BuildDependenciesGraph": {
          "title": "Build bependencies graph",
          "type": ["null", "boolean"]
        }
      }
    },
    "ProgrammingLanguages": {
      "title": "Active scanning languages",
      "type": "array",
      "uniqueItems": true,
      "items": {
        "type": "string",
        "enum": [
          "Java",
          "CSharp (Windows, Linux)",
          "CSharp (Windows)",
          "Php",
          "JavaScript",
          "Python",
          "ObjectiveC",
          "Swift",
          "CAndCPlusPlus",
          "Go",
          "Kotlin",
          "Sql",
          "Ruby",
          "Solidity",
          "Scala"
        ]
      }
    },
    "ProjectName": {
      "title": "Project name",
      "type": "string"
    },
    "BranchName": {
      "title": "Branch name",
      "type": ["string", "null"]
    },
    "ScanModules": {
      "title": "Enabled modules",
      "type": "array",
      "uniqueItems": true,
      "items": {
        "type": "string",
        "enum": [
          "Configuration",
          "Components",
          "BlackBox",
          "PatternMatching",
          "StaticCodeAnalysis",
          "SoftwareCompositionAnalysis"
        ]
      }
    },
    "SkipGitIgnoreFiles": {
      "title": "Skip .gitignore files",
      "description": "Exclude from scanning the files from the .gitignore file",
      "type": "boolean"
    },
    "ApplyAllPMRules": {
      "title": "Apply all PM rules",
      "description": "Apply all PM rules",
      "type": "boolean"
    },
    "UseSecurityPolicies": {
      "title": "Use security policies",
      "description": "Check for compliance with the security policy",
      "type": "boolean"
    }
  },
  "required": ["ProjectName", "ProgrammingLanguages", "ScanModules"],
  "title": "aiproj",
  "type": "object"
}
