<commit_before><?php
require 'vendor/autoload.php';
// First testing
$issuer = 'https://rp.certification.openid.net:8080/oidcfed_lib_php_rp/rp-response_type-code';
$oidc = new OpenIDConnectClient($issuer);
$oidc->register();
$cid = $oidc->getClientID();
$secret = $oidc->getClientSecret();
//----------
$curl = curl_init('https://rp.certification.openid.net:8080/oidcfed_php_rp/rp-response_type-code/.well-known/openid-configuration');
curl_setopt($curl, CURLOPT_FAILONERROR, true);
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
$result_curl = curl_exec($curl);
$result_pretty_print = json_encode(json_decode($result_curl), JSON_PRETTY_PRINT);
echo "<pre>";
//echo $result_curl;
echo $result_pretty_print;
echo "</pre>";<commit_msg>Cleaning and prepare steps for openid-connect federations check/certifications/tests...<commit_after><?php

require 'vendor/autoload.php';
// First testing dynaming registration ...
$issuer = 'https://rp.certification.openid.net:8080/oidcfed_lib_php_rp/rp-response_type-code';
$oidc = new OpenIDConnectClient($issuer);
$oidc->register();
$cid = $oidc->getClientID();
$secret = $oidc->getClientSecret();
$oidc_response_obj = new stdClass();
$oidc_response_obj->rp_id = "oidcfed_lib_php_rp";
$oidc_response_obj->test_id = "rp-response_type-code";
$oidc_response_obj->client_id = $cid;
$oidc_response_obj->client_secret = $secret;
$result_json = json_encode($oidc_response_obj, JSON_PARTIAL_OUTPUT_ON_ERROR);
try {
    file_put_contents('../oidc_dynamic_response.json', $result_json);
}
catch (Exception $exc) {
    echo $exc->getTraceAsString();
}

$result_json_pretty = json_encode($oidc_response_obj, JSON_PRETTY_PRINT);
try {
    file_put_contents('../oidc_dynamic_response_pretty.txt', $result_json_pretty);
}
catch (Exception $exc) {
    echo $exc->getTraceAsString();
}
//----------
// Nest test is rp-response_type-code

//----------
$curl = curl_init('https://rp.certification.openid.net:8080/oidcfed_php_rp/rp-response_type-code/.well-known/openid-configuration');
curl_setopt($curl, CURLOPT_FAILONERROR, true);
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
$result_curl = curl_exec($curl);
$result_pretty_print = json_encode(json_decode($result_curl), JSON_PRETTY_PRINT);
echo "<pre>";
//echo $result_curl;
echo $result_pretty_print;
echo "</pre>";
{'fraction_non_alphanumeric': 0.16384615384615384, 'fraction_numerical': 0.006153846153846154, 'mean_word_length': 7.102803738317757, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 19, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, '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': '6105462', 'n_tokens_mistral': 993, 'n_tokens_neox': 926, 'n_words': 135}