--- check_http.c.orig	2006-07-12 16:21:42.000000000 +0200
+++ check_http.c	2006-07-12 16:21:48.000000000 +0200
@@ -82,7 +82,9 @@
 int server_url_length;
 int server_expect_yn = 0;
 char server_expect[MAX_INPUT_BUFFER] = HTTP_EXPECT;
-char string_expect[MAX_INPUT_BUFFER] = "";
+char **string_expect = NULL;
+int string_expect_len = 0;
+int string_expect_fnd = 0;
 double warning_time = 0;
 int check_warning_time = FALSE;
 double critical_time = 0;
@@ -322,8 +324,13 @@
       http_post_data = strdup (optarg);
       break;
     case 's': /* string or substring */
-      strncpy (string_expect, optarg, MAX_INPUT_BUFFER - 1);
-      string_expect[MAX_INPUT_BUFFER - 1] = 0;
+      string_expect_len++;
+      string_expect=realloc(string_expect,sizeof(char*) * string_expect_len);
+      string_expect[string_expect_len-1] = malloc(MAX_INPUT_BUFFER); 
+      
+      strncpy (string_expect[string_expect_len-1], optarg, MAX_INPUT_BUFFER - 1);
+      string_expect[string_expect_len-1][MAX_INPUT_BUFFER - 1] = 0;
+
       break;
     case 'e': /* string or substring */
       strncpy (server_expect, optarg, MAX_INPUT_BUFFER - 1);
@@ -976,22 +983,26 @@
 
   /* Page and Header content checks go here */
   /* these checks should be last */
-
-  if (strlen (string_expect)) {
-    if (strstr (page, string_expect)) {
-      printf (_("HTTP OK %s - %.3f second response time %s%s|%s %s\n"),
-              status_line, elapsed_time,
-              timestamp, (display_html ? "</A>" : ""),
-              perfd_time (elapsed_time), perfd_size (pagesize));
-      exit (STATE_OK);
-    }
-    else {
-      printf (_("CRITICAL - string not found%s|%s %s\n"),
-              (display_html ? "</A>" : ""),
-              perfd_time (elapsed_time), perfd_size (pagesize));
-      exit (STATE_CRITICAL);
-    }
+  int g;
+  for (g=0;g < string_expect_len; g++){
+      if (strlen (string_expect[g])) {
+        if (strstr (page, string_expect[g]))
+          string_expect_fnd++;
+      }
   }
+  if (string_expect_fnd == string_expect_len) {
+    printf (_("HTTP OK %s - %.3f second response time %s%s|%s %s\n"),
+            status_line, elapsed_time,
+            timestamp, (display_html ? "</A>" : ""),
+            perfd_time (elapsed_time), perfd_size (pagesize));
+    exit (STATE_OK);
+  } else {
+    printf (_("CRITICAL - %d/%d strings found%s|%s %s\n"),string_expect_fnd,string_expect_len,
+            (display_html ? "</A>" : ""),
+            perfd_time (elapsed_time), perfd_size (pagesize));
+    exit (STATE_CRITICAL);
+  }
+
 #ifdef HAVE_REGEX_H
   if (strlen (regexp)) {
     errcode = regexec (&preg, page, REGS, pmatch, 0);
