<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Steve,<div class=""><br class=""></div><div class="">Thanks for this. Very helpful at this critical stage.</div><div class=""><br class=""></div><div class="">In general, I think your criteria is correct:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><blockquote type="cite" class="">My assumption going in is that all someone should be able to do before<br class="">enabling is to look at status that does not include sensitive info.</blockquote></div></blockquote><div class=""><br class=""></div><div class="">When not in secure mode, only very basic stuff should be usable. So, boot, enable, echo, exit, help, etc, are all ok. The ‘time status’ is fine, but no ‘time set’. etc.</div><div class=""><br class=""></div><div class="">The others should not be visible, imho. Metrics, Module, obdii; all should be secure mode only.</div><div class=""><br class=""></div><div class="">To answer your specific questions:</div><div class=""><br class=""></div><div class=""><blockquote type="cite" class="">1. obdii, server and simcom appear to allow their full functionality,<br class="">including starting and stopping operations, in non-secure mode. That<br class="">seems wrong.<br class=""></blockquote><div class=""><br class=""></div><div class="">The “simcom status”, “server v2 status”, “server v3 status” are fine, but the others should be secure only.</div><div class=""><br class=""></div><blockquote type="cite" class="">2. event, metrics and notify all allow tracing to be turned on or<br class="">off. Is that safe?<br class=""></blockquote><div class=""><br class=""></div>I think these should be secure only.</div><div class=""><br class=""></div><div class="">Metrics should probably be secure only as there is some private information shown there (such as ICCID, etc).</div><div class=""><br class=""><blockquote type="cite" class="">3. time allows setting the time in non-secure mode. That may not be<br class="">critical in this system, but could mess up timed activities.<br class=""></blockquote><div class=""><br class=""></div><div class="">The “time status” is fine, but “time set” is secure mode only.</div><br class=""><blockquote type="cite" class="">4. Setting the vehicle module should require being enabled, no?<br class=""></blockquote><div class=""><br class=""></div>Yes. Secure mode only.</div><div class=""><br class=""><blockquote type="cite" class="">5. Is it OK to list the metrics in non-secure mode? Is any of that<br class="">information sensitive enough that it should be prevented? (We don't<br class="">have the option to show some metrics and not others at this point.)<br class=""></blockquote><div class=""><br class=""></div>No. Better not. Secure mode only.</div><div class=""><br class=""><blockquote type="cite" class="">6. The module command only allowed the subcommand 'factory' which did<br class="">not allow any subcommand, so the right fix there is to just make the<br class="">whole command require secure mode. This observation exposed a bug in<br class="">the code to construct the usage string, which I fixed.</blockquote></div><div class=""><br class=""></div><div class="">Yes. Secure mode for the whole thing.</div><div class=""><br class=""></div><div class="">Regards, Mark</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 18 Mar 2018, at 3:23 PM, Stephen Casner <<a href="mailto:casner@acm.org" class="">casner@acm.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Mark asked me to check whether the 'secure' flag is set appropriately<br class="">in the various command invocation contexts. I began with the console<br class="">command list where there are a number of questionable settings. My<br class="">assumption going in is that all someone should be able to do before<br class="">enabling is to look at status that does not include sensitive info.<br class="">However, there are several commands that do more.<br class=""><br class="">All of these commands are at least partially enabled in non-secure<br class="">mode:<br class=""><br class="">OVMS > ?<br class="">boot BOOT framework<br class="">echo Test getchar<br class="">enable Enter secure mode<br class="">event EVENT framework<br class="">exit End console session<br class="">help Ask for help<br class="">metrics METRICS framework<br class="">module MODULE framework<br class="">network NETWORK framework<br class="">notify NOTIFICATION framework<br class="">obdii OBDII framework<br class="">server OVMS Server Connection framework<br class="">simcom SIMCOM framework<br class="">time TIME framework<br class="">vehicle Vehicle framework<br class=""><br class="">The harmless ones are 'boot', which just shows status, 'echo', 'exit'<br class="">and 'help'. Of course, 'enable' needs to be here to change state.<br class="">But I have questions about all the others:<br class=""><br class="">1. obdii, server and simcom appear to allow their full functionality,<br class="">including starting and stopping operations, in non-secure mode. That<br class="">seems wrong.<br class=""><br class="">2. event, metrics and notify all allow tracing to be turned on or<br class="">off. Is that safe?<br class=""><br class="">3. time allows setting the time in non-secure mode. That may not be<br class="">critical in this system, but could mess up timed activities.<br class=""><br class="">4. Setting the vehicle module should require being enabled, no?<br class=""><br class="">5. Is it OK to list the metrics in non-secure mode? Is any of that<br class="">information sensitive enough that it should be prevented? (We don't<br class="">have the option to show some metrics and not others at this point.)<br class=""><br class="">6. The module command only allowed the subcommand 'factory' which did<br class="">not allow any subcommand, so the right fix there is to just make the<br class="">whole command require secure mode. This observation exposed a bug in<br class="">the code to construct the usage string, which I fixed.<br class=""><br class="">So, basically, the question is what do we want someone to be able to<br class="">do in non-secure mode?<br class=""><br class=""> -- Steve<br class="">_______________________________________________<br class="">OvmsDev mailing list<br class=""><a href="mailto:OvmsDev@lists.teslaclub.hk" class="">OvmsDev@lists.teslaclub.hk</a><br class="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev<br class=""></div></div></blockquote></div><br class=""></div></body></html>