<pre style='margin:0'>
Kurt Hindenburg (kurthindenburg) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/ea83bd9902a1a346cda94b3f15f0fc1d1df3e055">https://github.com/macports/macports-ports/commit/ea83bd9902a1a346cda94b3f15f0fc1d1df3e055</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new ea83bd9 yara: move to github VirusTotal and update to 3.5.0
</span>ea83bd9 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit ea83bd9902a1a346cda94b3f15f0fc1d1df3e055
</span>Author: Kurt Hindenburg <khindenburg@macports.org>
AuthorDate: Fri Mar 3 23:46:54 2017 -0500
<span style='display:block; white-space:pre;color:#404040;'> yara: move to github VirusTotal and update to 3.5.0
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> py*-yara is now its own github repo; add --dynamic-linking
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> closes https://trac.macports.org/ticket/53512
</span>---
security/yara/Portfile | 26 ++++++++++++---------
security/yara/files/patch-259.diff | 24 +++++++++++++++++++
security/yara/files/patch-261.diff | 48 --------------------------------------
3 files changed, 39 insertions(+), 59 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/security/yara/Portfile b/security/yara/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index f8da248..5fc9730 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/security/yara/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/security/yara/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4,8 +4,7 @@ PortSystem 1.0
</span>
PortGroup github 1.0
<span style='display:block; white-space:pre;background:#ffe0e0;'>-github.setup plusvic yara 3.4.0 v
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-revision 1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+github.setup VirusTotal yara 3.5.0 v
</span> categories security
license GPL-2+
platforms darwin
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -17,12 +16,12 @@ long_description \
</span> YARA is a tool aimed at helping malware researchers to identify and \
classify malware samples.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-checksums rmd160 7453926c9deee005bda62dc252f37fe4bf769cd6 \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- sha256 43a597a48b1a5b39ea43de016db697c8d77d652e21e12848f166d9afaec1c5b6
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+checksums rmd160 956c39a78ec3c373687650e41db844d9e37ded51 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 7426bc3e35c96a8c996006d59bb4e8983fca10920ab6e12c9750dac71db924be
</span>
if {${subport} eq ${name}} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # https://github.com/plusvic/yara/pull/261
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- patchfiles patch-261.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # https://github.com/VirusTotal/yara/pull/259
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patchfiles patch-259.diff
</span> patch.pre_args -p1
depends_build port:autoconf \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -37,7 +36,7 @@ if {${subport} eq ${name}} {
</span> pre-configure {
system -W ${worksrcpath} "./bootstrap.sh"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # If yara 1.7 is installed, this build will fail since
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # If previous yara is installed, this build will fail since
</span> # /opt/local/include is before ./libyara/include
# so swap CPPFLAGS and CFLAGS
# Remove this upon the next release after verifying it is not needed.
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -51,6 +50,9 @@ if {${subport} eq ${name}} {
</span> configure.args-append --with-crypto \
--enable-cuckoo \
--enable-magic \
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.run yes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.target check
</span> }
set python.versions {27 34 35}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -62,29 +64,31 @@ foreach v ${python.versions} {
</span> set python.prefix ${frameworks_dir}/Python.framework/Versions/${python.branch}
subport py${python.version}-${name} {
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ github.setup VirusTotal yara-python 3.5.0 v
</span> categories security python
description ${name} bindings for python ${python.branch}
long_description Malware identification and classification tool. \
This subport provides bindings for python ${python.branch}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- worksrcdir ${github.project}-${version}/yara-python
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ checksums rmd160 f09802579ddde490a2b0873b54665c1db6a445a6 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 fa501b99c58ffc012467818a56c2fcd2a35d2823884edc1c3d75372de9caaa28
</span>
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_build-append port:py${python.version}-setuptools
</span> depends_lib-append port:${name} \
port:python${python.version}
use_configure no
build.cmd ${python.bin} setup.py --no-user-cfg
<span style='display:block; white-space:pre;background:#ffe0e0;'>- build.target build
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ build.target build --dynamic-linking
</span>
destroot.cmd ${python.bin} setup.py --no-user-cfg
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# destroot.target install --dynamic-linking
</span> destroot.destdir --prefix=${python.prefix} --root=${destroot}
test.run yes
test.cmd ${python.bin} tests.py
test.env PYTHONPATH=[glob -nocomplain ${worksrcpath}/build/lib*]
test.target
<span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- livecheck.type none
</span> }
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/security/yara/files/patch-259.diff b/security/yara/files/patch-259.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..5d490d7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/security/yara/files/patch-259.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,24 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git a/yara.c b/yara.c
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index 61fb234..42fb739 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/yara.c
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/yara.c
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1152,7 +1152,9 @@ int main(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ thread_args.rules = rules;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ thread_args.start_time = start_time;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- for (int i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ int i;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ for (i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (create_thread(&thread[i], scanning_thread, (void*) &thread_args))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1171,7 +1171,7 @@ int main(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ file_queue_finish();
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ // Wait for scan threads to finish
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- for (int i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ for (i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ thread_join(&thread[i]);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ file_queue_destroy();
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/security/yara/files/patch-261.diff b/security/yara/files/patch-261.diff
</span>deleted file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 8d4d6df..0000000
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/security/yara/files/patch-261.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,48 +0,0 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-diff --git a/libyara/modules/math.c b/libyara/modules/math.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-index 2365032..c2d1e34 100644
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>---- a/libyara/modules/math.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+++ b/libyara/modules/math.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -42,7 +42,9 @@ define_function(string_entropy)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (data == NULL)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- return_float(UNDEFINED);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- for (int i = 0; i < s->length; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ int i;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ for (i = 0; i < s->length; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- uint8_t c = s->c_string[i];
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- data[c] += 1;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -50,7 +52,7 @@ define_function(string_entropy)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- double entropy = 0.0;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- for (int i = 0; i < 256; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ for (i = 0; i < 256; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (data[i] != 0)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-diff --git a/yara.c b/yara.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-index 61fb234..42fb739 100644
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>---- a/yara.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+++ b/yara.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -1014,7 +1014,9 @@ int main(
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- thread_args.rules = rules;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- thread_args.start_time = start_time;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- for (int i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ int i;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ for (i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (create_thread(&thread[i], scanning_thread, (void*) &thread_args))
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -1033,7 +1035,7 @@ int main(
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- file_queue_finish();
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- // Wait for scan threads to finish
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- for (int i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ for (i = 0; i < threads; i++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- thread_join(&thread[i]);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- file_queue_destroy();
</span></pre><pre style='margin:0'>
</pre>