Commit bd5277d7 authored by Märt Rang's avatar Märt Rang
Browse files

Issue #3202136: Re-evaluate smart_id_resource_location path generation logics

parent f0c1e6e2
Loading
Loading
Loading
Loading
+1 −1
Changes for src/Controller/MobileIdController.php: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -131,7 +131,7 @@ class MobileIdController extends ControllerBase {
      $resource_location = NULL;

      if ($config->get('mobile_id_resource_location')) {
        $resource_location = DRUPAL_ROOT . '/' . $config->get('mobile_id_resource_location');
        $resource_location = $config->get('mobile_id_resource_location');
      }

      if (empty($resource_location)) {
+8 −1
Changes for src/Controller/SmartIdController.php: 8 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -125,9 +125,16 @@ class SmartIdController extends ControllerBase {
      $resource_location = NULL;

      if ($config->get('smart_id_resource_location')) {
        $resource_location = DRUPAL_ROOT . '/' . $config->get('smart_id_resource_location');
        $resource_location = $config->get('smart_id_resource_location');
      }

      if (empty($resource_location)) {
        // Default to test certificates.
        $resource_location = DRUPAL_ROOT . '/' . '../vendor/sk-id-solutions/smart-id-php-client/tests/resources';
      }

      $resource_location = rtrim($resource_location, '/') . '/';

      try {
        $authenticationResponseValidator = new AuthenticationResponseValidator($resource_location);
      }