[NETCONF-81] Netconf RPC replies don't comply with RFC 6241, section 3.2 Created: 09/Oct/15 Updated: 15/Mar/19 Resolved: 21/Dec/15 |
|
| Status: | Resolved |
| Project: | netconf |
| Component/s: | netconf |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Jozef Behran | Assignee: | Unassigned |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| External issue ID: | 4446 |
| Description |
|
The RFC 6241, section 3.2 states that "Document Type Definitions MUST NOT appear in NETCONF content". Yet when I emit a request, the response I get from ODL contains a document type declaration. I heard that there are devices which are not compliant with this RFC section by requiring these document type definitions to interoperate (Juniper?) but I can easily imagine that a device fails to interoperate when these document type definitions are present in the responses. So to fix this bug and allow for interoperability it would be best to make the behavior configurable, with the default set to "do not send document type definitions". If this is already configurable, then the problem is that the default is wrong. I just unpack the distribution, add Netconf to boot features, run Karaf and start sending the requests and the result is that the document types are sent in each reply. See the test suite at https://git.opendaylight.org/gerrit/#/c/27672 where you can see that all the *-reply.msg files contain the document type definitions; this test suite is passing but it should fail as these expected replies are not RFC compliant. |
| Comments |
| Comment by Jozef Behran [ 06/Nov/15 ] |
|
This might be also a bug in the RFC 6241 itself. In section "3" it states that "A NETCONF message MAY begin with an XML declaration" but in "3.2" it states "Document type declarations ... MUST NOT appear in NETCONF content." They did not specify exactly what "NETCONF content" actually means but from the overall tone of the RFC I came to the conclusion that they meant "NETCONF message", hence this bug. I thus vote for removal of the XML declarations from the NETCONF replies as I can easily imagine a device that does not expect them with this belief based on the section "3.2". |
| Comment by Tomas Cere [ 21/Dec/15 ] |
|
XML declaration and document type declaration(DOCTYPE) are not the same thing. |