Explorar o código

Merge branch 'candidate-8.4.x' into candidate-8.6.x

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
Richard Chapman %!s(int64=3) %!d(string=hai) anos
pai
achega
449801f00b

+ 6 - 3
ecl/hql/hqlcollect.cpp

@@ -517,9 +517,12 @@ void FileSystemDirectory::processDependencies(IDirectoryIterator * dir)
         const char * tail = pathTail(filename);
         if (file.isDirectory() == fileBool::foundYes)
         {
-            //If there is a directory within node_module, then treat that directory as a package
-            PackageDependency * depend = new PackageDependency(createIdAtom(tail), filename, false);
-            contents.append(*depend);
+            if (isValidIdentifier(tail))
+            {
+                //If there is a directory within node_module, then treat that directory as a package
+                PackageDependency * depend = new PackageDependency(createIdAtom(tail), filename, false);
+                contents.append(*depend);
+            }
         }
         else if (file.isFile() == fileBool::foundYes)
         {

+ 15 - 0
ecl/hql/hqlexpr.cpp

@@ -17204,6 +17204,21 @@ unsigned __int64 querySeqId(IHqlExpression * seq)
 #endif
 }
 
+bool isValidIdentifier(const char * text)
+{
+    if (!isalpha(*text))
+        return false;
+
+    for (;;)
+    {
+        byte next = *++text;
+        if (!next)
+            return true;
+        if (!isalnum(next) && (next != '_'))
+            return false;
+    }
+}
+
 /*
 List of changes:
 

+ 2 - 0
ecl/hql/hqlexpr.hpp

@@ -1995,4 +1995,6 @@ extern HQL_API void sanityCheckTransformation(const char * title, const HqlExprA
 extern HQL_API void sanityCheckTransformation(const char * title, IHqlExpression * before, IHqlExpression * after);
 extern HQL_API void sanityCheckTransformation(const char * title, IHqlExpression * before, const HqlExprArray & after);
 
+extern HQL_API bool isValidIdentifier(const char * text);
+
 #endif

+ 5 - 0
ecl/hql/hqlrepository.cpp

@@ -36,6 +36,11 @@ static const char * queryExtractFilename(const char * urn)
     case '/':
         return urn;
     }
+#ifdef _WIN32
+    //Check for drive:....
+    if (*urn && (urn[1] == ':'))
+        return urn;
+#endif
     return nullptr;
 }
 

+ 1 - 1
esp/src/eclwatch/WUDetailsWidget.js

@@ -320,7 +320,7 @@ define([
             this.statusNode = dom.byId(this.id + "WUStatus");
             srcReact.render(srcReact.WUStatus, { wuid: params.Wuid }, this.statusNode);
 
-            this.protected.on("change", function (evt) {
+            this.protected.on("click", function (evt) {
                 context._onSave();
             });
 

+ 5 - 5
helm/managed/logging/elastic/Chart.yaml

@@ -5,10 +5,10 @@ type: application
 
 # This is the chart version. This version number should be incremented each time you make changes
 # to the chart and its templates, including the app version.
-version: 1.2.1
+version: 1.2.2
 
 # Elastic Stack version
-appVersion: 7.16.2
+appVersion: 7.16.3
 
 # Dependencies can be automatically updated via HELM dependancy update command:
 # > 'helm dependency update' command
@@ -16,12 +16,12 @@ appVersion: 7.16.2
 # > helm install myelastic ./ —-dependency-update
 dependencies:
 - name: filebeat
-  version: 7.16.2
+  version: 7.16.3
   repository: https://helm.elastic.co
 - name: elasticsearch
-  version: 7.16.2
+  version: 7.16.3
   repository: https://helm.elastic.co
 - name: kibana # Optional managed logging processor front-end
-  version: 7.16.2
+  version: 7.16.3
   repository: https://helm.elastic.co
   condition: kibana.enabled

+ 7 - 0
helm/managed/logging/elastic/README.md

@@ -21,6 +21,13 @@
     <tr>
       <td>
         <ul>
+          <li>elastic4hpcclogs chart version 1.2.2 references Elastic Stack 7.16.3 (Log4j 2.17.1) which "By default, Elasticsearch and Logstash have no known vulnerabilities to CVE-2021-44832."</li>
+        </ul>
+      </td>
+    </tr>
+    <tr>
+      <td>
+        <ul>
           <li>elastic4hpcclogs chart version 1.2.1 references Elastic Stack 7.16.2 (Log4j 2.17.0) which reportedly fully mitigates CVE-2021-44228 and should avoid false positives in vulnerability scanners.</li>
           <li>Learn more about Elastic's 7.16.2 release and their response to the vulnerability: https://discuss.elastic.co/t/apache-log4j2-remote-code-execution-rce-vulnerability-cve-2021-44228-esa-2021-31/291476</li>
         </ul>

+ 2 - 1
roxie/ccd/ccdmain.cpp

@@ -1415,7 +1415,8 @@ int CCD_API roxie_main(int argc, const char *argv[], const char * defaultYaml)
                         }
                         const char *soname =  roxieFarm.queryProp("@so");
                         const char *config  = roxieFarm.queryProp("@config");
-                        Owned<IHpccProtocolPlugin> protocolPlugin = ensureProtocolPlugin(*protocolCtx, soname);
+                        // NB: leaks - until we fix bug in ensureProtocolPlugin() whereby some paths return a linked object and others do not
+                        IHpccProtocolPlugin *protocolPlugin = ensureProtocolPlugin(*protocolCtx, soname);
                         roxieServer.setown(protocolPlugin->createListener(protocol ? protocol : "native", createRoxieProtocolMsgSink(ip, port, numThreads, suspended), port, listenQueue, config, certFileName.str(), keyFileName.str(), passPhraseStr.str()));
                     }
                     else

+ 4 - 0
system/jlib/jdebug.cpp

@@ -1096,7 +1096,11 @@ void getCpuInfo(unsigned &numCPUs, unsigned &CPUSpeed)
 static unsigned evalAffinityCpus()
 {
     unsigned numCpus = 0;
+#ifdef __64BIT__
+    DWORD64 ProcessAffinityMask, SystemAffinityMask;
+#else
     DWORD ProcessAffinityMask, SystemAffinityMask;
+#endif
     if (GetProcessAffinityMask(GetCurrentProcess(), (PDWORD_PTR)&ProcessAffinityMask, (PDWORD_PTR)&SystemAffinityMask))
     {
         unsigned i = 0;