diff --git a/cas.install b/cas.install
index 6f8755e..e8324c7 100644
--- a/cas.install
+++ b/cas.install
@@ -370,3 +370,10 @@ function cas_update_7101() {
   }
   variable_del('cas_check_first');
 }
+
+/**
+ * Implements hook_enable().
+ */
+function cas_enable() {
+  drupal_set_message(t('CAS has been enabled. Please <a href="@url">configure</a> it.', array('@url' => url('admin/config/people/cas'))), 'warning');
+}
diff --git a/cas.module b/cas.module
index 4cf3769..5271b83 100644
--- a/cas.module
+++ b/cas.module
@@ -74,8 +74,10 @@ function cas_login_check($force_authentication = TRUE) {
   drupal_session_start();
   _cas_single_sign_out_save_ticket();  // We use this later for CAS 3 logoutRequests
 
-  // Initialize phpCAS.
-  cas_phpcas_init();
+  // Initialize phpCAS if possible, otherwise just back out.
+  if (cas_phpcas_init() === FALSE) {
+    return;
+  }
 
   // We're going to try phpCAS auth test
   if ($force_authentication) {
@@ -247,11 +249,14 @@ function cas_phpcas_init() {
 
   // Variable set
   $server_version    = (string)variable_get('cas_version', '2.0');
-  $server_cas_server = (string)variable_get('cas_server', 'sso-cas.univ-rennes1.fr');
+  $server_cas_server = (string)variable_get('cas_server', '');
   $server_port       = (int)variable_get('cas_port', '443');
   $server_uri        = (string)variable_get('cas_uri', '');
   $cas_cert          = (string)variable_get('cas_cert', '');
   $debug_file        = (string)variable_get('cas_debugfile', '');
+  if ($server_cas_server == '') {
+    return FALSE;
+  }
   if ($debug_file != '') {
     phpCAS::setDebug($debug_file);
   }
diff --git a/cas.test b/cas.test
index 46f6c15..a946cc6 100644
--- a/cas.test
+++ b/cas.test
@@ -31,6 +31,9 @@ class CasTestHelper extends DrupalWebTestCase {
     // in phpCAS.
     variable_set('clean_url', TRUE);
 
+    // Set CAS server url (will be altered).
+    variable_set('cas_server', 'example.com');
+
     // Create admin user.
     $this->admin_user = $this->drupalCreateUser(array('administer users', 'administer cas'));
 
