Description: Fix typos in upstream source
 This patch fix typos detected by Debian's lintian in 
 the Snort binary and the Snort libraries
Author: Javier Fernández-Sanguino Peña <jfs@debian.org>
Origin: vendor
Last-Update: 2021-09-05


--- a/ChangeLog
+++ b/ChangeLog
@@ -7586,7 +7586,7 @@
       - SMTP/IMAP/POP will now extract non-encoded attachments when
         content-type MIME headers are present.
       - SMTP will not decode when ignore_data is present.
-      - Content-Transfer-Encoding should take precendence over
+      - Content-Transfer-Encoding should take precedence over
         Content-Type.
       - Content-type should first check if boundary in non MIME header
         state.
--- a/src/detection-plugins/sp_byte_extract.c
+++ b/src/detection-plugins/sp_byte_extract.c
@@ -238,7 +238,7 @@
 
     if (data->base && !data->data_string_convert_flag)
     {
-        ParseError("byte_extract rule option has a string converstion type "
+        ParseError("byte_extract rule option has a string convertion type "
                    "(\"dec\", \"hex\", or \"oct\") without the \"string\" "
                    "argument.");
     }
--- a/src/dynamic-plugins/sf_engine/examples/3665.c
+++ b/src/dynamic-plugins/sf_engine/examples/3665.c
@@ -139,7 +139,7 @@
         if (contentMatch(p, rule3665options[1]->option_u.content, &cursor_normal) > 0) {
             // flowbits:set "mysql.server_greeting";
             if (processFlowbits(p, rule3665options[2]->option_u.flowBit) > 0) {
-                printf("not alerting, but thats ok!\n");
+                printf("not alerting, but that's ok!\n");
                     // flowbits:noalert;
                 /* NOTE: Not including any further functions for testing! */
                 return RULE_NOMATCH;
--- a/src/dynamic-plugins/sf_engine/examples/bug34427.c
+++ b/src/dynamic-plugins/sf_engine/examples/bug34427.c
@@ -1,5 +1,5 @@
 /*
- * MISC IBM Lotus Domino LDAP server invalide DN message buffer overflow attempt
+ * MISC IBM Lotus Domino LDAP server invalid DN message buffer overflow attempt
  *
  * Copyright (C) 2014-2019 Cisco and/or its affiliates. All rights reserved.
  * Copyright (C) 2007-2013 Sourcefire, Inc. All Rights Reserved
@@ -126,7 +126,7 @@
 
        "attempted-admin", /* classification, generic */
        0,  /* hardcoded priority XXX NOT PROVIDED BY GRAMMAR YET! */
-       "MISC IBM Lotus Domino LDAP server invalide DN message buffer overflow attempt",     /* message */
+       "MISC IBM Lotus Domino LDAP server invalid DN message buffer overflow attempt",     /* message */
        ruleDOMINO_LDAP_INVALID_DNrefs, /* ptr to references */
        NULL /* Meta data */
    },
--- a/src/dynamic-preprocessors/dcerpc2/dce2_config.c
+++ b/src/dynamic-preprocessors/dcerpc2/dce2_config.c
@@ -3649,7 +3649,7 @@
     if (i != DCE2_PORTS__MAX)
     {
         if (sc->smb_max_chain == 0)
-            _dpd.logMsg("    Maximum SMB command chaining: Unlimitied\n");
+            _dpd.logMsg("    Maximum SMB command chaining: Unlimited\n");
         else if (sc->smb_max_chain == 1)
             _dpd.logMsg("    Maximum SMB command chaining: No chaining allowed\n");
         else
--- a/src/dynamic-preprocessors/dnp3/dnp3_roptions.c
+++ b/src/dynamic-preprocessors/dnp3/dnp3_roptions.c
@@ -90,7 +90,7 @@
     if (params == NULL)
     {
         DynamicPreprocessorFatalMessage("%s(%d): dnp3_func requires a "
-            "number beween 0 and 255, or a valid function name.\n",
+            "number between 0 and 255, or a valid function name.\n",
             *_dpd.config_file, *_dpd.config_line);
     }
 
@@ -112,7 +112,7 @@
         if ((func_code > 255) || (func_code < 0) || (*endptr != '\0'))
         {
             DynamicPreprocessorFatalMessage("%s(%d): dnp3_func requires a "
-                "number beween 0 and 255, or a valid function name.\n",
+                "number between 0 and 255, or a valid function name.\n",
                 *_dpd.config_file, *_dpd.config_line);
         }
     }
@@ -123,7 +123,7 @@
         if (func_code == -1)
         {
             DynamicPreprocessorFatalMessage("%s(%d): dnp3_func requires a "
-                "number beween 0 and 255, or a valid function name.\n",
+                "number between 0 and 255, or a valid function name.\n",
                 *_dpd.config_file, *_dpd.config_line);
         }
     }
@@ -208,7 +208,7 @@
     if (params == NULL)
     {
         DynamicPreprocessorFatalMessage("%s(%d): dnp3_ind requires a "
-            "number beween 0 and 255, or a valid function name.\n",
+            "number between 0 and 255, or a valid function name.\n",
             *_dpd.config_file, *_dpd.config_line);
     }
 
--- a/src/log.c
+++ b/src/log.c
@@ -1377,7 +1377,7 @@
             break;
 
         case ICMP_ROUTER_ADVERTISE:
-            fprintf(fp, "ROUTER ADVERTISMENT: "
+            fprintf(fp, "ROUTER ADVERTISEMENT: "
                     "Num addrs: %d Addr entry size: %d Lifetime: %u",
                     p->icmph->s_icmp_num_addrs, p->icmph->s_icmp_wpa,
                     ntohs(p->icmph->s_icmp_lifetime));
--- a/src/log_text.c
+++ b/src/log_text.c
@@ -1247,7 +1247,7 @@
             break;
 
         case ICMP_ROUTER_ADVERTISE:
-            TextLog_Print(log, "ROUTER ADVERTISMENT: "
+            TextLog_Print(log, "ROUTER ADVERTISEMENT: "
                     "Num addrs: %d Addr entry size: %d Lifetime: %u",
                     p->icmph->s_icmp_num_addrs, p->icmph->s_icmp_wpa,
                     ntohs(p->icmph->s_icmp_lifetime));
--- a/src/parser.c
+++ b/src/parser.c
@@ -1777,7 +1777,7 @@
     DEBUG_WRAP(DebugMessage(DEBUG_PORTLISTS,"Rule-PortVar Parsed: %s \n",port_str););
 
     /* !ports - port lists can be mixed 80:90,!82,
-    * so the old NOT flag is depracated for port lists
+    * so the old NOT flag is deprecated for port lists
     */
 
     /* set up any any flags */
@@ -4749,7 +4749,7 @@
  *
  * Returns: void function
  *
- * Notes:  specialGID is depracated, uses sigInfo.shared flag
+ * Notes:  specialGID is deprecated, uses sigInfo.shared flag
  *
  *****************************************************************************/
 void SetRuleStates(SnortConfig *sc)
--- a/src/preprocessors/snort_httpinspect.c
+++ b/src/preprocessors/snort_httpinspect.c
@@ -1939,7 +1939,7 @@
                 if( (Precedence > XFF_MAX_PREC) || (Precedence < XFF_MIN_PREC) )
                 {
                     SnortSnprintf(ErrorString, ErrStrLen,
-                                 "illegal precendence value: %u", Precedence);
+                                 "illegal precedence value: %u", Precedence);
                     if( Field_Name )
                         free(Field_Name);
                     return( -1 );
@@ -2167,7 +2167,7 @@
     if(strcmp(START_PORT_LIST, pcToken))
     {
         SnortSnprintf(ErrorString, ErrStrLen,
-                "Must start an algotithm list with the '%s' token.",
+                "Must start an algorithm list with the '%s' token.",
                 START_PORT_LIST);
 
         return -1;
--- a/src/sfutil/mpse.c
+++ b/src/sfutil/mpse.c
@@ -4,7 +4,7 @@
 *   mpse.c
 *
 *   An abstracted interface to the Multi-Pattern Matching routines,
-*   thats why we're passing 'void *' objects around.
+*   that's why we're passing 'void *' objects around.
 *
 *   Copyright (C) 2014-2019 Cisco and/or its affiliates. All rights reserved.
 *   Copyright (C) 2002-2013 Sourcefire, Inc.
--- a/src/sfutil/sfportobject.c
+++ b/src/sfutil/sfportobject.c
@@ -2551,7 +2551,7 @@
     parray = calloc(1,SFPO_MAX_PORTS);
     if(!parray)
     {
-        FatalError("Memory eror in PortTableComopile\n");
+        FatalError("Memory error in PortTableComopile\n");
     }
 
     /*  Make sure each port is only in one composite port object */
@@ -3442,7 +3442,7 @@
         {
             buffer[k++]=(char)c;
             buffer[k]  =0;
-            if( k == sizeof(buffer)-1 ) break; /* thats all that fits */
+            if( k == sizeof(buffer)-1 ) break; /* that's all that fits */
         }
         else
         {
--- a/src/target-based/sf_attribute_table_parser.c
+++ b/src/target-based/sf_attribute_table_parser.c
@@ -7836,7 +7836,7 @@
     if (feof(sfatin))
     {
         SnortSnprintf(sfat_error_message, STD_BUF,
-            "%s(%d): Emtpy target-based attribute file: '%s'\n",
+            "%s(%d): Empty target-based attribute file: '%s'\n",
             file_name, file_line, filename);
         fclose(sfatin);
         return ret;
--- a/src/target-based/sf_attribute_table_parser.l
+++ b/src/target-based/sf_attribute_table_parser.l
@@ -218,7 +218,7 @@
     if (feof(yyin))
     {
         SnortSnprintf(sfat_error_message, STD_BUF,
-            "%s(%d): Emtpy target-based attribute file: '%s'\n",
+            "%s(%d): Empty target-based attribute file: '%s'\n",
             file_name, file_line, filename);
         fclose(yyin);
         return ret;
--- a/src/fpcreate.c
+++ b/src/fpcreate.c
@@ -992,7 +992,7 @@
     else if( !strcasecmp(method,"mwm") )
     {
        fp->search_method = MPSE_LOWMEM;
-       LogMessage("   Search-Method = Low-Mem (MWM depracated)\n");
+       LogMessage("   Search-Method = Low-Mem (MWM deprecated)\n");
     }
     else if( !strcasecmp(method,"lowmem-q") ||
              !strcasecmp(method,"lowmem") )
