<?php // We do not need this file any more @unlink('privatekey.php'); $ltikey = __mod_lti_verify_private_key(); $enrol_lti = __mod_lti_verify_private_key(); echo '<kid>'.$ltikey['kid'].'</kid>'; echo '<privatekey>'.$ltikey['privatekey'].'</privatekey>'; echo '<enrol_lti_kid>'.$enrol_lti['kid'].'</enrol_lti_kid>'; echo '<enrol_lti_privatekey>'.$enrol_lti['privatekey'].'</enrol_lti_privatekey>'; function __mod_lti_verify_private_key() { global $error; if (!function_exists('openssl_random_pseudo_bytes')) { $error[] = "openssl must be loaded for openssl_random_pseudo_bytes to function"; return null; } // Create the private key. $kid = bin2hex(openssl_random_pseudo_bytes(10)); $config = array( "digest_alg" => "sha256", "private_key_bits" => 2048, "private_key_type" => OPENSSL_KEYTYPE_RSA, ); $res = openssl_pkey_new($config); openssl_pkey_export($res, $privatekey); return array( 'kid' => $kid, 'privatekey' => $privatekey, ); } ?>
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
images | Folder | 0755 |
|
|
languages | Folder | 0755 |
|
|
php53 | Folder | 0755 |
|
|
php56 | Folder | 0755 |
|
|
php71 | Folder | 0755 |
|
|
php81 | Folder | 0755 |
|
|
php82 | Folder | 0755 |
|
|
NOTES.txt | File | 2.22 KB | 0644 |
|
add_admin.php | File | 733 B | 0644 |
|
check_utf8.php | File | 6.99 KB | 0644 |
|
clone.php | File | 5.49 KB | 0644 |
|
config.php | File | 745 B | 0644 |
|
data.zip | File | 7.42 KB | 0644 |
|
edit.php | File | 4.61 KB | 0644 |
|
edit.xml | File | 433 B | 0644 |
|
extend.php | File | 12.43 KB | 0644 |
|
fileindex.php | File | 1002 B | 0644 |
|
get_plugin_list.php | File | 766 B | 0644 |
|
import.php | File | 7.26 KB | 0644 |
|
info.xml | File | 3.87 KB | 0644 |
|
install.js | File | 924 B | 0644 |
|
install.php | File | 11.22 KB | 0644 |
|
install.xml | File | 3.36 KB | 0644 |
|
md5 | File | 3.48 KB | 0644 |
|
moodle30.sql | File | 1.21 MB | 0644 |
|
moodle30.zip | File | 90.04 MB | 0644 |
|
privatekey.php | File | 975 B | 0644 |
|
update_pass.php | File | 541 B | 0644 |
|
upgrade.php | File | 9.42 KB | 0644 |
|
upgrade.xml | File | 307 B | 0644 |
|