From d5e43ecb670d0258c39d55139df0a1edf6046571 Mon Sep 17 00:00:00 2001 From: Chris Pittman Date: Tue, 28 Nov 2023 12:02:25 -0600 Subject: [PATCH] update canvas urls --- src/PlatformCreator.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/PlatformCreator.php b/src/PlatformCreator.php index 6dd982f..175ad5a 100644 --- a/src/PlatformCreator.php +++ b/src/PlatformCreator.php @@ -63,14 +63,14 @@ public static function createLTI1p3PlatformCanvasCloud( $client_id ) { - foreach (['.instructure.com','.beta.instructure.com','.test.instructure.com'] as $base_url) { - $platform_id = 'https://canvas' . $base_url; + foreach (['','.beta','.test'] as $env) { + $platform_id = 'https://canvas' . $env . '.instructure.com'; $rsa_key = null; // a public key is not required if a JKU is available $signature_method = 'RS256'; - $jku = 'https://sso' . $base_url . '/api/lti/security/jwks'; - $authentication_url = 'https://sso' . $base_url . '/api/lti/authorize_redirect'; - $access_token_url = 'https://sso' . $base_url . '/login/oauth2/token'; + $jku = 'https://sso' . $env . '.canvaslms.com/api/lti/security/jwks'; + $authentication_url = 'https://sso' . $env . '.canvaslms.com/api/lti/authorize_redirect'; + $access_token_url = 'https://sso' . $env . '.canvaslms.com/login/oauth2/token'; $authorization_server_id = null; // defaults to the Access Token URL self::createLTI1p3Platform( $dataConnector,