Re: M3UA: Message Length

"David Laight" <[email protected]> Mon, 14 Oct 2013 10:20:28 +0100
Newsgroups gmane.ietf.sigtran
Message-ID <[email protected]>
This is a multi-part message in MIME format.

--===============3152851296497883342==
Content-class: urn:content-classes:message
Content-Type: multipart/alternative;
	boundary="----_=_NextPart_001_01CEC8BE.9F9E5EA7"

This is a multi-part message in MIME format.

------_=_NextPart_001_01CEC8BE.9F9E5EA7
Content-Type: text/plain;
	charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

I=92ve NFI what you used to take that trace =96 Wireshark will only give =
me a hexdump.

Anyway the packet decodes as:

=20

Pad, MAC addresses, ethertype

0000  00 00 00 01 00 06 00 1a  30 2b 4b c0 00 00 08 00

IP header

0010  45 02 00 ac 13 31 00 00  fe 84 3f ca 0a 3a 70 c8

0020  0a 3a e3 94

SCTP

      ports: 0f 53 0f 59

      tag:   49 33 5f c5

      cksum: 7f 3e b6 8d

0030  chunk type: 00

      flags:      03

      length:     00 8a

      TSN:        da 58 6c 93

      Stream id:  00 01

      Stream-seq: 00 08

      Payload-id: 00 00 00 03

=20

M3UA data, length 0x7c

0040  01 00 01 01 00 00 00 7c

            02 00 00 08

                  00 00 00 02

0050        00 06 00 08

                  00 00 00 08

            02 10 00 62

                  00 00 0b ba

0060              00 00 13 8b 03 03 01 00  11 01 03 04 08 0c 45 04

0070              43 8b 13 07 04 43 ba 0b  07 39 00 00 00 00 00 00

0080              00 00 00 00 00 00 00 00  00 00 00 00 00 00 04 04

0090              04 04 04 04 04 04 04 04  04 04 04 04 04 04 04 04

00a0              04 04 04 04 04 04 04 04  04 04 04 04 04 04 04 04

00b0              04 04 04 10 04 40 00 00  00 00

=20

Inter-chunk pad: 00 00

=20

The problem is that the length of the M3UA message (0x7c)  is larger =
than the payload

part of the SCTP message (0x8a =96 0x10 =3D 0x7a).

The RFC might let you send that if the M3UA length were 0x7a, but I know =
that

all implementations will not be able to receive such messages =96 so it =
is best not

to send them.

=20

                David

=20

=20

From: santosh nayak [mailto:[email protected]]=20
Sent: 14 October 2013 05:47
To: David Laight
Subject: Re: [Sigtran] M3UA: Message Length

=20

Hi,

=20

Thanks for the response...

=20

I am attaching the pcap... packet number 85

Could you explain what MUST is violated???

=20

Thanks,

Santosh

=20

=20

On Thu, Oct 10, 2013 at 5:57 PM, David Laight <[email protected]> =
wrote:

> From: [email protected] [mailto:[email protected]] On =
Behalf Of Michael Tuexen

> On Oct 10, 2013, at 11:40 AM, santosh nayak =
<[email protected]> wrote:
>
> > Hi,
> >
> > We have a situation where message is being rejected at M3UA layer =
due to
> > buffer length is not equal to message length.
> >
> > What is the significance of Message Length and its importance with =
padding...
> >
> > in the current issue M3UA peer is sending the data buffer of size =
122 bytes
> > to KSCTP. But message length parameter of M3UA common header =
contains a value
> > of 124 and KSCTP is doing the padding at its level of 2 bytes which =
is
> > observed from the wireshark traces.

Are you sure that pad isn't just from SCTP aligning it's chunks?


> > Now at DUT message droped with reason  (message length parameter is =
greater
> > than actual M3UA data buffer size)
> >
> > Is this expected??? Please comment on this...
>
> At least the behaviour of the sender is not expected, since the sender
> violates a MUST.

I'm not sure what the note in section 3.1.4 is trying to allow, but
I think the message you are describing is definitely illegal.

I believe that the overall length in the 'common' header should always
match that of the SCTP data chunk.
This allows M3UA data to be separated into messages when sent using =
(say)
TCP rather than SCTP.

I suspect the note allows an implementation to add the pad (following a
parameter) when it adds a new one, rather than when it adds a parameter
that isn't a multiple of 4 bytes.

In any case I'd change your sending end.

        David




=20


=0D=0A
=0D=
------_=_NextPart_001_01CEC8BE.9F9E5EA7
Content-Type: text/html;
	charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" =
xmlns:o=3D"urn:schemas-microsoft-com:office:office" =
xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:m=3D"http://schemas.microsoft.com/office/2004/12/omml" =
xmlns=3D"http://www.w3.org/TR/REC-html40"><head><meta =
http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dwindows-1252"><meta name=3DGenerator content=3D"Microsoft Word =
12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
	{font-family:Calibri;
	panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
	{font-family:Tahoma;
	panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
	{font-family:"Lucida Console";
	panose-1:2 11 6 9 4 5 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0cm;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
	{mso-style-priority:99;
	color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{mso-style-priority:99;
	color:purple;
	text-decoration:underline;}
span.hoenzb
	{mso-style-name:hoenzb;}
span.EmailStyle18
	{mso-style-type:personal-reply;
	font-family:"Calibri","sans-serif";
	color:#1F497D;}
.MsoChpDefault
	{mso-style-type:export-only;}
@page WordSection1
	{size:612.0pt 792.0pt;
	margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
	{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]--></head><body lang=3DEN-GB link=3Dblue =
vlink=3Dpurple><div class=3DWordSection1><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>I=92ve NFI what you used to take that trace =96 Wireshark will only =
give me a hexdump.<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>Anyway the packet decodes as:<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>Pad, MAC =
addresses, ethertype<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>0000=A0 00 00 00 =
01 00 06 00 1a=A0 30 2b 4b c0 00 00 08 00<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>IP =
header<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>0010=A0 45 02 00 =
ac 13 31 00 00=A0 fe 84 3f ca 0a 3a 70 c8<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>0020=A0 0a 3a e3 =
94<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>SCTP<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
ports: 0f 53 0f 59<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
tag:=A0=A0 49 33 5f c5<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
cksum: 7f 3e b6 8d<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>0030=A0 chunk =
type: 00<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
flags:=A0=A0=A0=A0=A0 03<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
length:=A0=A0=A0=A0 00 8a<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
TSN:=A0=A0=A0=A0=A0=A0=A0 da 58 6c 93<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
Stream id:=A0 00 01<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
Stream-seq: 00 08<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>=A0=A0=A0=A0=A0 =
Payload-id: 00 00 00 03<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>M3UA data, length =
0x7c<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>0040=A0 01 00 01 =
01 00 00 00 7c<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 02 00 00 =
08<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 00 00 00 =
02<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>0050=A0=A0=A0=A0=A0=A0=A0 00 06 00 08<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 00 00 00 =
08<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 02 10 00 =
62<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 00 00 0b =
ba<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>0060=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 00 00 13 8b 03 03 =
01 00=A0 11 01 03 04 08 0c 45 04<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>0070=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 43 8b 13 07 04 43 =
ba 0b=A0 07 39 00 00 00 00 00 00<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>0080=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 00 00 00 00 00 00 =
00 00=A0 00 00 00 00 00 00 04 04<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>0090=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 04 04 04 04 04 04 =
04 04=A0 04 04 04 04 04 04 04 04<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>00a0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 04 04 04 04 04 04 =
04 04=A0 04 04 04 04 04 04 04 04<o:p></o:p></span></p><p =
class=3DMsoNormal style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'>00b0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 04 04 04 10 04 40 =
00 00=A0 00 00<o:p></o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida =
Console"'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal =
style=3D'text-autospace:none'><span =
style=3D'font-size:9.0pt;font-family:"Lucida Console"'>Inter-chunk pad: =
00 00<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>The problem is that the length of the M3UA message (0x7c)=A0 is =
larger than the payload<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>part of the SCTP message (0x8a =96 0x10 =3D =
0x7a).<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>The RFC might let you send that if the M3UA length were 0x7a, but I =
know that<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>all implementations will not be able to receive such messages =96 so =
it is best not<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>to send them.<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 =
David<o:p></o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span =
style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497=
D'><o:p>&nbsp;</o:p></span></p><div =
style=3D'border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm =
4.0pt'><div><div style=3D'border:none;border-top:solid #B5C4DF =
1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=3DMsoNormal><b><span =
lang=3DEN-US =
style=3D'font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span>=
</b><span lang=3DEN-US =
style=3D'font-size:10.0pt;font-family:"Tahoma","sans-serif"'> santosh =
nayak [mailto:[email protected]] <br><b>Sent:</b> 14 October =
2013 05:47<br><b>To:</b> David Laight<br><b>Subject:</b> Re: [Sigtran] =
M3UA: Message Length<o:p></o:p></span></p></div></div><p =
class=3DMsoNormal><o:p>&nbsp;</o:p></p><div><p =
class=3DMsoNormal>Hi,<o:p></o:p></p><div><p =
class=3DMsoNormal><o:p>&nbsp;</o:p></p></div><div><p =
class=3DMsoNormal>Thanks for the response...<o:p></o:p></p></div><div><p =
class=3DMsoNormal><o:p>&nbsp;</o:p></p></div><div><p class=3DMsoNormal>I =
am attaching the pcap... packet number 85<o:p></o:p></p></div><div><p =
class=3DMsoNormal>Could you explain what MUST is =
violated???<o:p></o:p></p></div><div><p =
class=3DMsoNormal><o:p>&nbsp;</o:p></p></div><div><p =
class=3DMsoNormal>Thanks,<o:p></o:p></p></div><div><p =
class=3DMsoNormal>Santosh<o:p></o:p></p></div><div><p =
class=3DMsoNormal><o:p>&nbsp;</o:p></p></div></div><div><p =
class=3DMsoNormal =
style=3D'margin-bottom:12.0pt'><o:p>&nbsp;</o:p></p><div><p =
class=3DMsoNormal>On Thu, Oct 10, 2013 at 5:57 PM, David Laight &lt;<a =
href=3D"mailto:[email protected]" =
target=3D"_blank">[email protected]</a>&gt; =
wrote:<o:p></o:p></p><p class=3DMsoNormal>&gt; From: <a =
href=3D"mailto:[email protected]">[email protected]</a> =
[mailto:<a =
href=3D"mailto:[email protected]">[email protected]</a>] =
On Behalf Of Michael Tuexen<o:p></o:p></p><div><p class=3DMsoNormal =
style=3D'margin-bottom:12.0pt'>&gt; On Oct 10, 2013, at 11:40 AM, =
santosh nayak &lt;<a =
href=3D"mailto:[email protected]">[email protected]</a>&g=
t; wrote:<br>&gt;<br>&gt; &gt; Hi,<br>&gt; &gt;<br>&gt; &gt; We have a =
situation where message is being rejected at M3UA layer due to<br>&gt; =
&gt; buffer length is not equal to message length.<br>&gt; &gt;<br>&gt; =
&gt; What is the significance of Message Length and its importance with =
padding...<br>&gt; &gt;<br>&gt; &gt; in the current issue M3UA peer is =
sending the data buffer of size 122 bytes<br>&gt; &gt; to KSCTP. But =
message length parameter of M3UA common header contains a value<br>&gt; =
&gt; of 124 and KSCTP is doing the padding at its level of 2 bytes which =
is<br>&gt; &gt; observed from the wireshark =
traces.<o:p></o:p></p></div><p class=3DMsoNormal>Are you sure that pad =
isn't just from SCTP aligning it's chunks?<o:p></o:p></p><div><p =
class=3DMsoNormal style=3D'margin-bottom:12.0pt'><br>&gt; &gt; Now at =
DUT message droped with reason &nbsp;(message length parameter is =
greater<br>&gt; &gt; than actual M3UA data buffer size)<br>&gt; =
&gt;<br>&gt; &gt; Is this expected??? Please comment on =
this...<br>&gt;<br>&gt; At least the behaviour of the sender is not =
expected, since the sender<br>&gt; violates a =
MUST.<o:p></o:p></p></div><p class=3DMsoNormal =
style=3D'margin-bottom:12.0pt'>I'm not sure what the note in section =
3.1.4 is trying to allow, but<br>I think the message you are describing =
is definitely illegal.<br><br>I believe that the overall length in the =
'common' header should always<br>match that of the SCTP data =
chunk.<br>This allows M3UA data to be separated into messages when sent =
using (say)<br>TCP rather than SCTP.<br><br>I suspect the note allows an =
implementation to add the pad (following a<br>parameter) when it adds a =
new one, rather than when it adds a parameter<br>that isn't a multiple =
of 4 bytes.<br><br>In any case I'd change your sending end.<br><span =
style=3D'color:#888888'><br><span class=3Dhoenzb>&nbsp; &nbsp; &nbsp; =
&nbsp; David</span><br><br><br></span><o:p></o:p></p></div><p =
class=3DMsoNormal><o:p>&nbsp;</o:p></p></div></div></div>
<br>=
<FONT face=3DTahoma color=3D#484830 size=3D2></FONT>=0D=0A
<DIV><FONT face=3DTahoma color=3D#484830 size=3D1>Registered Address Lakeside, Br=
amley Road, Mount Farm, Milton Keynes, MK1 1PT, UK<BR>Registration No: 13973=
86 (Wales)</FONT></DIV>=0D=0A
<DIV><FONT face=3DArial color=3D#008000 size=3D2><FONT face=3DWebdings size=3D5>=0D=0A
<P align=3Dcenter><FONT face=3DArial color=3D#008000><FONT size=3D1><FONT face=3DWebd=
ings>P<STRONG> </STRONG></FONT><STRONG>Please consider the environment and d=
on't print this e-mail unless you really need to</STRONG></FONT></FONT></P><=
/FONT></FONT></DIV>
<br>=
</body></html>
------_=_NextPart_001_01CEC8BE.9F9E5EA7--

--===============3152851296497883342==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Sigtran mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/sigtran

--===============3152851296497883342==--