Can you show me this malformed error packet, and tell me in what way
it is malformed?
On Tue, May 22, 2012 at 09:50:20AM +0000, Prabina Pattnaik wrote:
> Hi Ben,
>
> We agree that implementation of 'at least 64 bytes' is as per spec (to allow
> data above 64 bytes depends on vendor specific switch implementation).
> But in current implementation, when the code (mentioned below) limits the
> size of data to 64 bytes (if data field of the error packet is more than 64
> bytes), a malformed OFPFMFC_BAD_COMMAND error packets gets generated (visible
> on wireshark with openflow plugin).
>
> As per our analysis, removal of code to limit the data size to 64, resolves
> the issue of malformed packet.
>
> File: lib/ofputil.c
> Routine ofputil_encode_error_msg
>
> If (oh){
> Xid = oh->xid;
> data = oh;
> len = ntohs(oh->length);
> - if (len > 64){
> - len =64;
> - }
> }
>
>
> Regards,
> Prabina
>
>
> -----Original Message-----
> From: Ben Pfaff [mailto:[email protected]]
> Sent: Monday, May 21, 2012 10:24 PM
> To: Prabina Pattnaik
> Cc: [email protected]
> Subject: Re: [ovs-discuss] OpenVSwitch - Error packet OFPFMFC_BAD_COMMAND of
> code ofp_flow_mod_failed_code coming as malformed.
>
> On Mon, May 21, 2012 at 11:15:28AM +0000, Prabina Pattnaik wrote:
> > As per openflow 1.0 spec "data" contains at "least" first 64 bytes
> > of failed request. This is working correct also in current OVS 1.2.2
> > code.
> >
> > But it is taking an extra check in code (lib/ofp-util.c) on "data"
> > length that:-
> >
> > if data is greater than 64 bytes then it would be truncated to 64
> > bytes which is making this packet as malformed. OVS code is working
> > on "at most" 64 bytes length instead of "at least" 64 bytes.
> >
> > To avoid the truncation of 'data field ' to 64 bytes, the condition
> > to check the length of data field in file (lib/ofp-util.c), routine
> > ofputil_encode_error_msg can be removed.
>
> I disagree with your interpretation. "At least" 64 bytes means that
> OVS is allowed to truncate the inner message after 64 bytes. That is
> what it is doing.
>
>
>
> DISCLAIMER:
>
> -----------------------------------------------------------------------------------------------------------------------
>
> The contents of this e-mail and any attachment(s) are confidential and
> intended
>
> for the named recipient(s) only.
>
> It shall not attach any liability on the originator or NECHCL or its
>
> affiliates. Any views or opinions presented in
>
> this email are solely those of the author and may not necessarily reflect the
>
> opinions of NECHCL or its affiliates.
>
> Any form of reproduction, dissemination, copying, disclosure, modification,
>
> distribution and / or publication of
>
> this message without the prior written consent of the author of this e-mail is
>
> strictly prohibited. If you have
>
> received this email in error please delete it and notify the sender
>
> immediately. .
>
> -----------------------------------------------------------------------------------------------------------------------
_______________________________________________
discuss mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/discuss