summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-misc/zaptel/files')
-rw-r--r--net-misc/zaptel/files/zaptel-1.2.27-CVE-2008-5396.patch64
1 files changed, 64 insertions, 0 deletions
diff --git a/net-misc/zaptel/files/zaptel-1.2.27-CVE-2008-5396.patch b/net-misc/zaptel/files/zaptel-1.2.27-CVE-2008-5396.patch
new file mode 100644
index 000000000000..6c26d8aa84b0
--- /dev/null
+++ b/net-misc/zaptel/files/zaptel-1.2.27-CVE-2008-5396.patch
@@ -0,0 +1,64 @@
+svn diff -c 4587 http://svn.digium.com/svn/zaptel/branches/1.2/
+see https://issues.asterisk.org/view.php?id=13954
+Index: wcte11xp.c
+===================================================================
+--- wcte11xp.c (revision 4586)
++++ wcte11xp.c (revision 4587)
+@@ -932,7 +932,7 @@
+ span->txlevel = lc->lbo;
+ span->rxlevel = 0;
+ /* Do we want to SYNC on receive or not */
+- wc->sync = lc->sync;
++ wc->sync = (lc->sync) ? 1 : 0;
+ /* If already running, apply changes immediately */
+ if (span->flags & ZT_FLAG_RUNNING)
+ return t1xxp_startup(span);
+Index: tor2.c
+===================================================================
+--- tor2.c (revision 4586)
++++ tor2.c (revision 4587)
+@@ -203,6 +203,13 @@
+
+ if (debug)
+ printk("Tor2: Configuring span %d\n", span->spanno);
++
++ if ((lc->sync < 0) || (lc->sync >= SPANS_PER_CARD)) {
++ printk(KERN_WARNING "%s %d: invalid span timing value %d.\n",
++ THIS_MODULE->name, span->spanno, lc->sync);
++ return -EINVAL;
++ }
++
+ /* XXX We assume lineconfig is okay and shouldn't XXX */
+ span->lineconfig = lc->lineconfig;
+ span->txlevel = lc->lbo;
+Index: torisa.c
+===================================================================
+--- torisa.c (revision 4586)
++++ torisa.c (revision 4587)
+@@ -602,6 +602,13 @@
+ {
+ if (debug)
+ printk("TorISA: Configuring span %d\n", span->spanno);
++
++ if ((lc->sync < 0) || (lc->sync >= 2)) {
++ printk(KERN_WARNING "%s %d: invalid span timing value %d.\n",
++ THIS_MODULE->name, span->spanno, lc->sync);
++ return -EINVAL;
++ }
++
+ /* XXX We assume lineconfig is okay and shouldn't XXX */
+ span->lineconfig = lc->lineconfig;
+ span->txlevel = lc->lbo;
+Index: wct1xxp.c
+===================================================================
+--- wct1xxp.c (revision 4586)
++++ wct1xxp.c (revision 4587)
+@@ -738,7 +738,7 @@
+ span->txlevel = lc->lbo;
+ span->rxlevel = 0;
+ /* Do we want to SYNC on receive or not */
+- wc->sync = lc->sync;
++ wc->sync = (lc->sync) ? 1 : 0;
+ /* If already running, apply changes immediately */
+ if (span->flags & ZT_FLAG_RUNNING)
+ return t1xxp_startup(span);