Moodle SEB setup illustration

Safe Exam Browser Moodle Setup: Complete Integration Guide

Safe Exam Browser article image

Moodle is one of the most popular learning management systems (LMS) in the world, and Safe Exam Browser integrates directly with Moodle's quiz module to enforce secure exam conditions. When configured correctly, Moodle will only allow students to access a quiz if they are using an authenticated, unmodified copy of SEB. This guide covers the complete integration process from both the administrator and student perspectives.

How SEB and Moodle Work Together

The integration between Moodle and Safe Exam Browser relies on a cryptographic handshake. When a student accesses a Moodle quiz URL using SEB, the browser sends a special HTTP header called the Browser Exam Key (BEK). This key is a hash derived from the SEB configuration and the current URL. Moodle verifies this key against a value the administrator configured during quiz setup. If the keys match, the student is granted access. If they do not match — for example, if the student is using a different browser or a modified version of SEB — access is denied.

This mechanism ensures that only students using the exact, legitimate SEB configuration specified by the institution can access the exam, making it extremely difficult to bypass the lockdown without being detected.

Prerequisites

  • A working Moodle installation (version 3.9 or later recommended; Moodle 4.x fully supported)
  • Moodle administrator or course creator role
  • Safe Exam Browser installed on at least one machine for testing and key generation
  • A published Moodle quiz to configure

Configuring Moodle Quiz Settings

Follow these steps within Moodle to enable SEB protection on a quiz:

1

Open Quiz Settings

Go to your Moodle course, click the quiz you want to protect, then click the gear icon and select Edit settings.

2

Expand Extra Restrictions

Scroll down to the Extra restrictions on attempts section and expand it.

3

Require Safe Exam Browser

In the "Require the use of Safe Exam Browser" dropdown, select Yes — show SEB download link. This adds a download prompt for students who do not yet have SEB installed.

4

Enter the Browser Exam Key

In the "Allowed Browser Exam Keys" field, paste the Browser Exam Key generated by your SEB configuration. Instructions for generating this key are in the next section.

5

Save Changes

Scroll to the bottom of the settings page and click Save and return to course.

Understanding the Browser Exam Key (BEK)

The Browser Exam Key is a SHA-256 hash that combines your SEB configuration settings with the current page URL. It changes with every URL, which means it cannot simply be copied from one site to another. Here is how to obtain it:

  1. Install Safe Exam Browser on your test machine.
  2. Create a SEB configuration file with the settings appropriate for your exam (covered in the next section).
  3. Launch SEB using your configuration file so that it navigates to your Moodle quiz URL.
  4. In SEB, press F6 (Windows) or navigate to the SEB taskbar menu to view the current Browser Exam Key displayed for the current URL.
  5. Copy this key exactly — including all characters — and paste it into the Moodle quiz settings field.
Moodle quiz configuration illustration
Moodle quiz configuration illustration

Using the Config Key

Moodle 3.9 and later also supports a Config Key, which is a hash of the SEB configuration file itself (not the URL). Using the Config Key instead of the BEK offers a significant advantage: it does not change with the URL, making it easier to manage across multiple quiz pages. The Config Key is displayed in the SEB Preferences window under the Exam tab after you load a configuration file.

To use Config Key in Moodle: select "Config Key" as the required SEB key type in the quiz's Extra Restrictions settings, then paste the Config Key value. Students must use the exact configuration file that generated this key — any modification will result in a different hash and access will be denied.

Creating the SEB Configuration File

You create SEB configuration files using the Safe Exam Browser Preferences window. Open SEB on Windows or macOS, then:

  • Go to Preferences (Windows: Ctrl+P or Start Menu > SEB Preferences; macOS: Cmd+, or SEB menu > Preferences).
  • Under the General tab, enter your Moodle quiz URL as the Start URL.
  • Under the Browser tab, configure allowed and blocked URLs if needed.
  • Under the Applications tab, specify any applications to terminate or permit during the exam.
  • Under the Exam tab, set a quit password so students cannot exit SEB independently.
  • Click Apply and restart SEB to test, then go to File > Export Preferences as SEB File to save your .seb configuration file.

Distribute this .seb file to students before the exam. When they double-click it, SEB will launch with your exact settings and navigate directly to the exam URL.

Testing the Integration

Before deploying to students, always test the complete flow on a representative machine:

  1. Double-click the .seb configuration file. SEB should launch and navigate to the Moodle quiz URL.
  2. Log in with a test student account. Moodle should allow access if the BEK or Config Key matches.
  3. Attempt a few quiz questions to ensure Moodle works correctly inside SEB.
  4. Test the quit password to confirm students cannot exit unexpectedly.
  5. Test on both Windows and macOS if students use both platforms, as the BEK can differ between operating systems.

Student Experience

From a student's perspective, the process is simple:

  1. Receive the .seb configuration file from their institution before the exam day.
  2. Install Safe Exam Browser if not already installed.
  3. On exam day, double-click the .seb file. SEB launches and navigates to the exam.
  4. Log in to Moodle with their student credentials.
  5. The quiz opens. SEB prevents all other applications and browsing until the exam is complete.
  6. After submitting, the administrator or a countdown timer enables SEB to close.

Frequently Asked Questions

Yes. Moodle has built-in Safe Exam Browser support in its Quiz module's "Extra Restrictions" settings. No additional plugin is required for basic BEK-based integration in Moodle 3.9 and later.
No. The BEK is URL-specific and changes with each quiz URL. Use the Config Key instead if you want a single key value that works across all quiz pages for the same SEB configuration.
Moodle will display an error page and prevent the student from accessing the quiz. This typically means they are using a different browser, a modified SEB configuration, or a different version of SEB than the one used to generate the key.
Yes. Safe Exam Browser is fully compatible with Moodle 4.x. The integration process is the same as for Moodle 3.x.

Set Up Safe Exam Browser with Moodle Today

Download SEB for your platform and follow this guide to deploy secure online exams through Moodle.

Download Safe Exam Browser