Wang Weidong | 5 Dec 04:06 2013

[PATCH] x25: convert printks to pr_<level>

use pr_<level> instead of printk(LEVEL)

Signed-off-by: Wang Weidong <wangweidong1 <at> huawei.com>
---
 net/x25/af_x25.c         |  2 +-
 net/x25/x25_dev.c        |  8 ++++----
 net/x25/x25_facilities.c | 12 ++++++------
 net/x25/x25_forward.c    |  2 +-
 net/x25/x25_in.c         |  2 +-
 net/x25/x25_link.c       |  4 ++--
 net/x25/x25_subr.c       |  4 ++--
 7 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
index 7622789..5142a40 100644
--- a/net/x25/af_x25.c
+++ b/net/x25/af_x25.c
 <at>  <at>  -1809,7 +1809,7  <at>  <at>  static int __init x25_init(void)
 	if (rc != 0)
 		goto out_sock;

-	printk(KERN_INFO "X.25 for Linux Version 0.2\n");
+	pr_info("X.25 for Linux Version 0.2\n");

 	x25_register_sysctl();
 	rc = x25_proc_init();
diff --git a/net/x25/x25_dev.c b/net/x25/x25_dev.c
index a8a2363..ccf8fd9 100644
--- a/net/x25/x25_dev.c
+++ b/net/x25/x25_dev.c
(Continue reading)

Michael Drüing | 28 Oct 18:33 2013
Picon

[PATCH] net: x25: Fix dead URLs in Kconfig

Update the URLs in the Kconfig file to the new pages at sangoma.com and cisco.com

Signed-off-by: Michael Drüing <michael <at> drueing.de>
---
 net/x25/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/net/x25/Kconfig b/net/x25/Kconfig
index c959312c..e2fa133 100644
--- a/net/x25/Kconfig
+++ b/net/x25/Kconfig
 <at>  <at>  -16,8 +16,8  <at>  <at>  config X25
 	  if you want that) and the lower level data link layer protocol LAPB
 	  (say Y to "LAPB Data Link Driver" below if you want that).

-	  You can read more about X.25 at <http://www.sangoma.com/x25.htm> and
-	  <http://www.cisco.com/univercd/cc/td/doc/product/software/ios11/cbook/cx25.htm>.
+	  You can read more about X.25 at <http://www.sangoma.com/tutorials/x25/> and
+	  <http://docwiki.cisco.com/wiki/X.25>.
 	  Information about X.25 for Linux is contained in the files
 	  <file:Documentation/networking/x25.txt> and
 	  <file:Documentation/networking/x25-iface.txt>.
--

-- 
1.8.3.1

Guenther Kelleter | 18 Oct 14:03 2013

[PATCH] X.25: Fix address field length calculation

Addresses are BCD encoded, not ASCII. x25_addr_ntoa got it right.

Signed-off-by: Guenther Kelleter <gkelleter <at> datus.com>
---
Wrong length calculation leads to rejection of CALL ACCEPT packets.

(patch resubmitted without corruption by stupid thunderbird. grrrr.)

 net/x25/af_x25.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
index 45a3ab5..2daf224 100644
--- a/net/x25/af_x25.c
+++ b/net/x25/af_x25.c
 <at>  <at>  -98,7 +98,7  <at>  <at>  int x25_parse_address_block(struct sk_buff *skb,
 	}

 	len = *skb->data;
-	needed = 1 + (len >> 4) + (len & 0x0f);
+	needed = 1 + ((len >> 4) + (len & 0x0f) + 1) / 2;

 	if (!pskb_may_pull(skb, needed)) {
 		/* packet is too short to hold the addresses it claims
--

-- 
1.8.3.4.71.g0878476

Kelleter, Günther | 15 Oct 16:29 2013

[PATCH] X.25: Fix address field length calculation

Addresses are BCD encoded, not ASCII. x25_addr_ntoa got it right.

Signed-off-by: Guenther Kelleter <gkelleter <at> datus.com>
---
Wrong length calculation leads to rejection of CALL ACCEPT packets.

 net/x25/af_x25.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
index 45a3ab5..2daf224 100644
--- a/net/x25/af_x25.c
+++ b/net/x25/af_x25.c
 <at>  <at>  -98,7 +98,7  <at>  <at>  int x25_parse_address_block(struct sk_buff *skb,
 	}
  	len = *skb->data;
-	needed = 1 + (len >> 4) + (len & 0x0f);
+	needed = 1 + ((len >> 4) + (len & 0x0f) + 1) / 2;
  	if (!pskb_may_pull(skb, needed)) {
 		/* packet is too short to hold the addresses it claims
--

-- 
1.8.3.4.71.g0878476
Kelleter, Günther | 2 Oct 13:21 2013

[PATCH] X.25: Fix address field length calculation

Addresses are BCD encoded, not ASCII. x25_addr_ntoa got it right.

Signed-off-by: Guenther Kelleter <gkelleter <at> datus.com>
---
 net/x25/af_x25.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
index 45a3ab5..2daf224 100644
--- a/net/x25/af_x25.c
+++ b/net/x25/af_x25.c
 <at>  <at>  -98,7 +98,7  <at>  <at>  int x25_parse_address_block(struct sk_buff *skb,
 	}
  	len = *skb->data;
-	needed = 1 + (len >> 4) + (len & 0x0f);
+	needed = 1 + ((len >> 4) + (len & 0x0f) + 1) / 2;
  	if (!pskb_may_pull(skb, needed)) {
 		/* packet is too short to hold the addresses it claims
--

-- 
1.8.3.4.71.g0878476
Dan Carpenter | 3 Sep 11:03 2013
Picon

[patch] x25: add a sanity check parsing X.25 facilities

This was found with a manual audit and I don't have a reproducer.  We
limit ->calling_len and ->called_len when we get them from
copy_from_user() in x25_ioctl() so when they come from skb->data then
we should cap them there as well.

Signed-off-by: Dan Carpenter <dan.carpenter <at> oracle.com>
---
Possibly should be applied to -stable.  My guess is that this leads to
memory corruption, but I don't know.

diff --git a/net/x25/x25_facilities.c b/net/x25/x25_facilities.c
index 66c63873..b825325 100644
--- a/net/x25/x25_facilities.c
+++ b/net/x25/x25_facilities.c
 <at>  <at>  -156,6 +156,8  <at>  <at>  int x25_parse_facilities(struct sk_buff *skb, struct x25_facilities *facilities,
 			case X25_FAC_CALLING_AE:
 				if (p[1] > X25_MAX_DTE_FACIL_LEN || p[1] <= 1)
 					return -1;
+				if (p[2] > X25_MAX_AE_LEN)
+					return -1;
 				dte_facs->calling_len = p[2];
 				memcpy(dte_facs->calling_ae, &p[3], p[1] - 1);
 				*vc_fac_mask |= X25_MASK_CALLING_AE;
 <at>  <at>  -163,6 +165,8  <at>  <at>  int x25_parse_facilities(struct sk_buff *skb, struct x25_facilities *facilities,
 			case X25_FAC_CALLED_AE:
 				if (p[1] > X25_MAX_DTE_FACIL_LEN || p[1] <= 1)
 					return -1;
+				if (p[2] > X25_MAX_AE_LEN)
+					return -1;
 				dte_facs->called_len = p[2];
(Continue reading)

Toralf Förster | 14 Aug 22:12 2013
Picon
Picon

s2disk broken (bisected) in 3.10.4

The following bisected commit 

commit ea4c218f2c3e67f1bca8078ff1f80d7e0c2ab791
Author: Dave Jones <davej <at> redhat.com>
Date:   Fri Jun 28 12:13:52 2013 -0400

    x25: Fix broken locking in ioctl error paths.

    [ Upstream commit 4ccb93ce7439b63c31bc7597bfffd13567fa483d ]

    Two of the x25 ioctl cases have error paths that break out of the function without
    unlocking the socket, leading to this warning:

breaks s2disk at a 32 bit stable Gentoo Linux (booted from an external USB drive).
Reverting that commit on top of 3.10.6 solved the issue.

After wakeup the cursor doesn't blink and the systems just hangs, magic sysrq works fortunately.

--

-- 
MfG/Sincerely
Toralf Förster
pgp finger print: 7B1A 07F4 EC82 0F90 D4C2 8936 872A E508 7DB6 9DA3
Stephen Moorby | 19 Jun 22:32 2013

[PATCH 1/1] net/x25: fix address parsing bug in x25_parse_address_block.

This problem was discovered when a linux box was incorrectly rejecting
calls from some X.25 equipment.  The problem was diagnosed to an incorrect
address length calculation in 'x25_parse_address_block', the calculation
did not account for the address digits being BCD encoded.  The correct
calculation is already performed on line 155.

Patched on linux-next 18-Jun-2013
Tested on 2.6.32-45-generic

Signed-off-by: Stephen Moorby <steve.moorby <at> ntlworld.com>
---
 net/x25/af_x25.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
index 1d964e2..eb6c1f9 100644
--- a/net/x25/af_x25.c
+++ b/net/x25/af_x25.c
 <at>  <at>  -98,7 +98,8  <at>  <at>  int x25_parse_address_block(struct sk_buff *skb,
 	}

 	len = *skb->data;
-	needed = 1 + (len >> 4) + (len & 0x0f);
+	/* need 1 for address length + bytes for BCD encoding of 2 addresses */
+	needed = 1 + (((len >> 4) + (len & 0x0f) + 1) >> 1);

 	if (!pskb_may_pull(skb, needed)) {
 		/* packet is too short to hold the addresses it claims
--

-- 
1.8.1.2
(Continue reading)

Stephen Moorby | 19 Jun 13:13 2013
Picon

[PATCH 1/1] net/x25: fix address parsing bug in x25_parse_address_block.

 From 01ba835311f6d2e2bbffc74703d704dc07803b53 Mon Sep 17 00:00:00 2001
From: Stephen Moorby <steve.moorby <at> ntlworld.com>
Date: Wed, 19 Jun 2013 11:48:53 +0100
Subject: [PATCH 1/1] net/x25: fix address parsing bug in
  x25_parse_address_block.

This problem was discovered when a linux box was incorrectly rejecting
calls from some X.25 equipment.  The problem was diagnosed to an incorrect
address length calculation in 'x25_parse_address_block', the calculation
did not account for the address digits being BCD encoded.  The correct
calculation is already performed on line 155.

Patched on linux-next 18-Jun-2013
Tested on 2.6.32-45-generic

Signed-off-by: Stephen Moorby <steve.moorby <at> ntlworld.com>
---
  net/x25/af_x25.c | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
index 1d964e2..eb6c1f9 100644
--- a/net/x25/af_x25.c
+++ b/net/x25/af_x25.c
 <at>  <at>  -98,7 +98,8  <at>  <at>  int x25_parse_address_block(struct sk_buff *skb,
      }

      len = *skb->data;
-    needed = 1 + (len >> 4) + (len & 0x0f);
+    /* need 1 for address length + bytes for BCD encoding of 2 addresses */
(Continue reading)

有效果再付款 | 22 Jul 22:49 2012
Picon

2012春季111届广交会买家,群发软件,B2B询盘买家、thomasnet 采购商,海关数据,展会买家 仅300元!

2012春季111届广交会买家,海关数据提单piers版,2008-2012年9届广交会数据。

一共10个包(数据是全行业的,可以按照关键词提取出来的):

1,2012春季111届广交会买家现场询盘数据库新鲜出炉,超级新鲜买家,新鲜数据,容易成单! 
2,购买后可以免费更新2012秋季广交会买家数据。太超值了。
3,2012最新全球展会现场买家库(与贸发同步),共46万条数据。 (按照行业分类)
4,2011,2010年,2009年,2008年 春季+秋季广交会买家名录,103 104 105 106 107
108,109,110 共六届 共120.6万数据。
5,48.68万条最新买家询盘,都带有Email,最有价值的询盘。
6,2011最新 B2B 英文国际站60万带联络方式询盘 最有价值询盘之一.
7,2010海关提单piers版1000万数据.
8,2011年到香港采购的国外客人名录(香港贸发局提供),超级重要的买家。
9,2011年新增加的-美国B2B thomasnet 采购商名单。
10,群发软件安装与部署服务。

这些全有,共1280万 数据。

 
要的抓紧联系QQ: 460122641 或者立即回复邮箱: 460122641 <at> qq.com
要的抓紧联系QQ: 460122641 或者立即回复邮箱: 460122641 <at> qq.com
要的抓紧联系QQ: 460122641 或者立即回复邮箱:
460122641 <at> qq.com

诚信为本,如果不信任本人,可以走淘宝交易,收到数据验证3天后再付款,这是对您最好的保障了。 



小技巧:

(Continue reading)

Sergey Lapin | 31 May 17:31 2012

[PATCH 1/2] LAPB: added 'delivered' interface

When using LAPB API for non-X.25 work, it is often necessary
to know if/when data is delivered to third party using LAPB
interface (e.g over serial or other media).

Signed-off-by: Sergey Lapin <slapin <at> ossfans.org>
---
 include/linux/lapb.h  |    1 +
 net/lapb/lapb_iface.c |    6 ++++++
 net/lapb/lapb_subr.c  |    1 +
 3 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/include/linux/lapb.h b/include/linux/lapb.h
index 873c1eb..fd963be 100644
--- a/include/linux/lapb.h
+++ b/include/linux/lapb.h
 <at>  <at>  -30,6 +30,7  <at>  <at>  struct lapb_register_struct {
 	void (*disconnect_indication)(struct net_device *dev, int reason);
 	int  (*data_indication)(struct net_device *dev, struct sk_buff *skb);
 	void (*data_transmit)(struct net_device *dev, struct sk_buff *skb);
+	void (*data_delivered)(struct net_device *dev, struct sk_buff *skb);
 };

 struct lapb_parms_struct {
diff --git a/net/lapb/lapb_iface.c b/net/lapb/lapb_iface.c
index 3cdaa04..0fe77ae 100644
--- a/net/lapb/lapb_iface.c
+++ b/net/lapb/lapb_iface.c
 <at>  <at>  -415,6 +415,12  <at>  <at>  int lapb_data_transmit(struct lapb_cb *lapb, struct sk_buff *skb)
 	return used;
 }
(Continue reading)


Gmane