Adobe Acrobat Connect(AC)-moodle Interface - implemented on LINUX/UNIX -- D. Winning / oncampus 2008 Automatic provision of AC-meetings and Users for moodle-courses plus SSO This Interface will provide a meeting-room within Abobe-Connect Pro 6/7 Conferencing-Suite to moodle (1.8, 1.9) in a way that a meeting-room will be associated to each moodle-course. Further any moodle-user created while the interface is active will be also created within AC with appropriate rights. moodle-users do not need to explicitly login to AC. A moodle-block is provided to quickly enter a room from within any course. A script exists to populate AC with users and rooms before the interface becomes active. This way AC can become an integral part of moodle and extends or even replace the moodle-chat. Data-flow from moodle to AC is secured by means of an extra database-table as intermediate store for moodle-commands. The queue is worked frequently using cron and stopped if an error-condition occurs. The interface is triggered by moodle-code directly, so there are minor changes to moodle. The following files will be altered: user/editadvanced.php admin/user.php course/edit.php course/delete.php admin/roles/assign.php These changes are provided as altered moodle-files which are moodle-version-dependant; our actual version is 1.8.2. Installation procedure summary: - setup database - alter moodle - install and configure interface-files - configure AC - populate table with existing moodle-data - setup cron - install moodle-AC-Block, configure moodle setup database: --------------- CREATE DATABASE `acqueue` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; USE `acqueue`; CREATE TABLE `synccmd` ( `id` int(10) NOT NULL AUTO_INCREMENT, `cmd` char(1) CHARACTER SET utf8 NOT NULL, `cid` varchar(255) CHARACTER SET utf8 DEFAULT NULL, `uid` varchar(255) CHARACTER SET utf8 DEFAULT NULL, `rid` varchar(255) CHARACTER SET utf8 DEFAULT NULL, `firstname` varchar(255) CHARACTER SET utf8 DEFAULT NULL, `lastname` varchar(255) CHARACTER SET utf8 DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; User “acuser”; grants: SELECT, INSERT, DELETE Configure connection-rights to this table for the moodle-host alter moodle: ------------- For every altered file add the following include: //AC-moodle require_once($CFG->dirroot.'/AC/acifwrite.php'); User-modification and addition .............................. -> user/editadvanced.php realm "create form": after "$usernew->id = insert_record('user', $usernew)" // AC-moodle new User aiw_Create_user($usernew->username, $usernew->firstname, $usernew->lastname); after ...else... "update_record('user', $usernew)" // AC-moodle mod User aiw_Modify_user($usernew->username, $usernew->firstname, $usernew->lastname); -deletion ................. -> admin/user.php beneath ...} else if ($delete... ...} else if (data_submitted()... innerhalb "if (update_record('user', $updateuser))" //AC-moodle delete user aiw_Delete_user($user->username); Meeting-room-addition ..................... -> course/edit.php realm "/// process data if submitted" inside "if (empty($course))"-block before ...redirect... //AC-new room aiw_Create_room($course->shortname); -deletion ................. -> course/delete.php bottom....: after: "delete_course($course->id);" //AC delete room aiw_Delete_room($course->shortname); Enrolment-addition and deletion ............................... -> admin/roles/assign.php realm: "/// Process incoming role assignment" inside: "if ($allow) { after "if (! role_assign..." //AC-moodle assign $zuser = get_record('user', 'id', $adduser); aiw_Assign($zuser->username, $course->shortname, $roleid); in the else-block within foreach after "if (! role_unassign..." //AC-moodle unassign $zuser = get_record('user', 'id', $removeuser); aiw_UnAssign($zuser->username, $course->shortname); install and configure interface-files: -------------------------------------- All files reside under the moodle-directory in the directory "AC" except for acenter.php, which has to be put to a http-accessible location (e.g. document root). User "moodle" is assumed as the UNIX-user for all moodle and this interface. Configuration of AC-moodle takes place in the file ac_conf.inc Consider the following entries: // Global values Connect $ac_host = 'connect.yourdomain.de'; $ac_port = 80; $ac_admin = 'admin'; $ac_xuserid = 'secret'; // meeting_folder_id is a static system-folder-id, look it up manually as admin using the URL for meetings/usermeetings $ac_meeting_folder_id = 1000x; $ac_logfile = '/var/log/moodle/ac_error.log'; $ac_db_host = 'localhost'; $ac_db_user = 'acuser'; $ac_db_pw = 'secret'; $ac_db_name = 'acqueue'; Mind http-settings for ac_conf.inc and its directory; web-accessibility of this file must be disallowed! ac_autogo.sh contains a mail-address for error-messages; change that accordingly configure AC: ------------- Adobe-(Acrobat)-Connect Professional 6 has to be extended by adding the API-connection-token and enabling the SSO-service. Edit .../appserv/conf/WEB-INF/web.xml: disable any section "HeaderAuthenticationFilter" containing "ignore..."; uncomment "HeaderAuthenticationFilter" beeing the active method set: ...url-pattern>/api/*<... Add the following line to .../custom.ini: HTTP_AUTH_HEADER=secret [password matches ac_xuserid in ac_conf.inc] Create an admin-user in AC using this password populate table with existing moodle-data: ----------------------------------------- The sync-database can be preloaded with data already in the moodle-database. This is done by running the script ...AC/acinit_moodle.php on the shell. Please mind that this process should only run once. To keep data in sync, the interface should be ready right after the script finished. Configure moodle-connection-settings inside the script. By default the script is exited for security reasons. setup cron: ----------- Set up a cron entry for user "moodle" like: # Trigger Sync AC 40 * * * * /usr/local/www/moodle/AC/ac_autogo.sh This way the sync is done every hour at the 40th minute. install moodle-AC-Block, configure moodle: ------------------------------------------ The Block is installed by copying the Block-directory "webkonf" to ...moodle/blocks and clicking the moodle-admin-link "notifications" once. Check the link inside the php-script; it must pass appropriate values and reflect the correct location of acenter.php ....href="'.$CFG->wwwroot.'/acenter.php?uid='.$USER->index.'&room='.$course->index.'.... where $USER->index by default is $USER->username and $course->index is $course->shortname The index must match those of the addition-actions within the patched moodle-php-scripts (see above) USAGE ***** Everytime a moodle-admin adds, alters or deletes a user or course, the interface becomes active and after the sync the changes are reflected within Adobe Connect. A sync can also be done manually anytime calling "php acifread.php" in a shell. Regular moodle-users enter meetings by using the block directly from within their courses. Admins do still login directly to the connect-service using their password. The roles of moodle and AC do match as follows: moodle-role id AC-API-ID AC-role ---------------------------------------------- guest 6 remove none student 5 view participant teacher 4 mini-host presenter editingteacher 3 host host This interface handles exactly one meetingroom per course; if there should be no meeting, disable the block. In case of more than one meeting-room those would have to be setup and entered manually, which would require an extra layer of user-administration thus leaving the scope of this interface.