HEX
Server: Apache/2.4.54 (Win64) OpenSSL/1.1.1q PHP/8.1.10
System: Windows NT ALTAIR 10.0 build 20348 (Windows Server 2022) AMD64
User: Administrator (0)
PHP: 8.1.10
Disabled: NONE
Upload Files
File: C:/laragon/www/newVip/PHPoktaServiziGetListaRuoli.php
<?php
include_once 'PHPSpringServer.php';
$jwt = $_POST["token"];

$curl = curl_init();
$spring = new SpringServer();
curl_setopt_array($curl, array(
  CURLOPT_URL => $spring->getUrl().'/servizi/listaPermessi',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_SSL_VERIFYPEER => false,
  CURLOPT_SSL_VERIFYHOST => false ,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => array(
   'Content-Type: application/json',
    'Auth: Bearer '.$jwt
  )
));

$response = curl_exec($curl);

$httpcode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
http_response_code($httpcode);
curl_close($curl);
echo $response;
?>