<div dir="auto">Yes, I was talking about ndncert and the current test deployment that is using ndn-cxx v0.6.6.<div dir="auto"><br></div><div dir="auto">Davide</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Nov 5, 2019, 2:17 PM Junxiao Shi <<a href="mailto:shijunxiao@email.arizona.edu">shijunxiao@email.arizona.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hi Davide</div><div><br></div><div>Frame 6 was generated by a different program that does not rely on ndn-cxx-0.6.6.</div><div>I just confirmed that the packet has the correct ParametersSha256DigestComponent, with the following snippet:</div><div><br></div><div><div style="color:rgb(212,212,212);background-color:rgb(30,30,30);font-family:Consolas,"Courier New",monospace;font-size:14px;line-height:19px;white-space:pre-wrap"><div><span style="color:rgb(106,153,85)">// g++ -std=c++14 -o x x.cpp $(pkg-config --cflags --libs libndn-cxx)</span></div><br><div><span style="color:rgb(197,134,192)">#include</span><span style="color:rgb(86,156,214)"> </span><span style="color:rgb(206,145,120)"><ndn-cxx/interest.hpp></span></div><div><span style="color:rgb(197,134,192)">#include</span><span style="color:rgb(86,156,214)"> </span><span style="color:rgb(206,145,120)"><ndn-cxx/encoding/block.hpp></span></div><div><span style="color:rgb(197,134,192)">#include</span><span style="color:rgb(86,156,214)"> </span><span style="color:rgb(206,145,120)"><ndn-cxx/util/string-helper.hpp></span></div><br><div><span style="color:rgb(197,134,192)">#include</span><span style="color:rgb(86,156,214)"> </span><span style="color:rgb(206,145,120)"><iostream></span></div><div><span style="color:rgb(197,134,192)">#include</span><span style="color:rgb(86,156,214)"> </span><span style="color:rgb(206,145,120)"><string></span></div><br><div><span style="color:rgb(78,201,176)">std</span>::string pkt = <span style="color:rgb(206,145,120)">"0571074208036e646e0803656475080475636c610806797566656e6708065f50524f42450220649503f51f30e5f9a3a76d6f1847bcce7208b64367a2459ac848ebfc91f47ed812000a046d1ddfd80c020f97241f7b22656d61696c223a22537573656e746572406461797265702e636f6d227d"</span>;</div><br><div><span style="color:rgb(86,156,214)">int</span> <span style="color:rgb(220,220,170)">main</span>() {</div><div>  <span style="color:rgb(78,201,176)">ndn</span>::Block <span style="color:rgb(220,220,170)">block</span>(<span style="color:rgb(78,201,176)">ndn</span>::<span style="color:rgb(220,220,170)">fromHex</span>(pkt));</div><div>  <span style="color:rgb(78,201,176)">ndn</span>::Interest <span style="color:rgb(220,220,170)">interest</span>(block);</div><div>  <span style="color:rgb(86,156,214)">bool</span> ok = <span style="color:rgb(156,220,254)">interest</span>.<span style="color:rgb(220,220,170)">isParametersDigestValid</span>();</div><div>  <span style="color:rgb(78,201,176)">std</span>::cout << <span style="color:rgb(86,156,214)">static_cast</span><<span style="color:rgb(86,156,214)">int</span>>(ok) << <span style="color:rgb(78,201,176)">std</span>::endl;</div><div>}</div><br></div></div><div><br></div><div>'pkt' was copied from Wireshark using "hex stream" mode. This snippet prints "1", indicating the digest is valid.</div><div>Thus, I believe this is a problem in NDNCERT-CA deployment.</div><div><br></div><div>Yours, Junxiao</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Nov 5, 2019 at 12:50 AM Davide Pesavento <<a href="mailto:davidepesa@gmail.com" target="_blank" rel="noreferrer">davidepesa@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Using ParametersSha256DigestComponent (and, by extension,<br>
ApplicationParameters) with ndn-cxx-0.6.6 or any earlier versions is a<br>
bad idea. You'd have to take care of the parameters digest manually,<br>
which I doubt ndncert is doing.<br>
<br>
Davide<br>
<br>
On Tue, Nov 5, 2019 at 12:32 AM Junxiao Shi<br>
<<a href="mailto:shijunxiao@email.arizona.edu" target="_blank" rel="noreferrer">shijunxiao@email.arizona.edu</a>> wrote:<br>
><br>
> Hi Zhiyi<br>
><br>
> It seems that the current deployment is not handling ParametersSha256DigestComponent correctly.<br>
><br>
> In the attached packet sample, frame 1 is a PROBE Interest generated by ndncert-client from <a href="https://github.com/Zhiyi-Zhang/ndncert/tree/3b9a2501d60e90ec33845e021a500a9820bf9050" rel="noreferrer noreferrer" target="_blank">https://github.com/Zhiyi-Zhang/ndncert/tree/3b9a2501d60e90ec33845e021a500a9820bf9050</a> .<br>
> The Interest is invalid under Packet Format 0.3, as it contains ApplicationParameters element but lacks ParametersSha256DigestComponent in the name.<br>
> Nevertheless, the CA responded to this Interest in frame 2.<br>
><br>
> Frame 6 was generated by a different program. It carries the same JSON object, and have a ParametersSha256DigestComponent appended to the name. However, the CA is not responding to it.<br>
> Did I generate the packet wrong, or is it a problem with the deployment?<br>
><br>
> Yours, Junxiao<br><br>
</blockquote></div></div>
</blockquote></div>