Index: modules/system/system.install
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.install,v
retrieving revision 1.443
diff -u -p -r1.443 system.install
--- modules/system/system.install	25 Jan 2010 21:32:44 -0000	1.443
+++ modules/system/system.install	26 Jan 2010 08:16:58 -0000
@@ -341,6 +341,25 @@ function system_requirements($phase) {
     }
   }
 
+  if (function_exists('apache_get_modules') && in_array('mod_security', apache_get_modules())) {
+    if ($phase == 'install' && !isset($_GET['nomodsecuritycheck'])) {
+      $requirements['mod_security_check'] = array(
+        'title'       => st('mod_security'),
+        'value'       => st('Apache module mod_security detected.'),
+        'severity'    => REQUIREMENT_ERROR,
+        'description' => st('The Apache module mod_security has been detected on your system. Depending on the rule set mod_security uses, the module can interfere with Drupal installation and use. Consult the <a href="@drupal-mod_security">online handbook</a> for more information. You may also ignore this warning and <a href="!url">continue installation</a>.', array('@drupal-mod_security' => 'http://drupal.org/mod_security-information', '!url' => check_url(request_uri()) .'&nomodsecuritycheck=1')),
+      );
+    }
+    else {
+      $requirements['mod_security_check'] = array(
+        'title'       => st('mod_security'),
+        'value'       => st('Apache module mod_security detected.'),
+        'severity'    => REQUIREMENT_WARNING,
+        'description' => st('The Apache module mod_security has been detected on your system. Depending on the rule set mod_security uses, the module can interfere with Drupal installation and use. Consult the <a href="@drupal-mod_security">online handbook</a> for more information.', array('@drupal-mod_security' => 'http://drupal.org/mod_security-information')),
+      );
+    }
+  }
+
   return $requirements;
 }
 
