<commit_before><?php
/**
 * Common Vulnerability Scoring System Version 3.0 Calculator [Preview 2]
 *
 * @desc Class to get and calculate cvss v3 score
 *
 * @author Security-Database <<EMAIL>>
 * @version 1.0
 * @package CVSSv3
 * @license http://www.apache.org/licenses/LICENSE-2.0  Apache License 2.0
 */

namespace CVSSv3;

/* Start use case */

try {

	$cvss = new \CVSSv3\Cvss();
	

	$cvss->register("CVSS:3.0/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:L/A:N/E:P/RL:W/CR:L/IR:L/MAV:A/MAC:H/MPR:L/MUI:N/MS:U/MC:L/MI:L/MA:L");
	print_r($cvss->scores);
	print_r($cvss->calcul);
	print_r($cvss->formula);
	print_r($cvss->vector);

} catch (Exception $e) {
	print $e->getCode()." : ".$e->getMessage();
}

/* End use case */



Class Cvss {


	public  $version = "preview 2";
	
	private $vector_input_array = array();

	private $metrics_check_mandatory = array("AV"=>"[N,A,L,P]",
											"AC"=>"[L,H]",
											"PR"=>"[N,L,H]",<commit_msg>Security-database CVSS v3 Class v1.0<commit_after><?php
/**
 * Common Vulnerability Scoring System Version 3.0 Calculator [Preview 2]
 *
 * @desc Class to get and calculate cvss v3 score
 *
 * @author Security-Database <<EMAIL>>
 * @version 1.0
 * @package CVSSv3
 * @license http://www.apache.org/licenses/LICENSE-2.0  Apache License 2.0
 */

namespace CVSSv3;

/* Start use case */
/*
try {

	$cvss = new \CVSSv3\Cvss();
	

	$cvss->register("CVSS:3.0/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:L/A:N/E:P/RL:W/CR:L/IR:L/MAV:A/MAC:H/MPR:L/MUI:N/MS:U/MC:L/MI:L/MA:L");
	print_r($cvss->scores);
	print_r($cvss->calcul);
	print_r($cvss->formula);
	print_r($cvss->vector);

} catch (Exception $e) {
	print $e->getCode()." : ".$e->getMessage();
}
*/
/* End use case */



Class Cvss {


	public  $version = "preview 2";
	
	private $vector_input_array = array();

	private $metrics_check_mandatory = array("AV"=>"[N,A,L,P]",
											"AC"=>"[L,H]",
											"PR"=>"[N,L,H]",
{'fraction_non_alphanumeric': 0.2168164992067689, 'fraction_numerical': 0.01850872554204125, 'mean_word_length': 3.6034063260340634, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3571184', 'n_tokens_mistral': 890, 'n_tokens_neox': 815, 'n_words': 139}