cesanta / mongoose-wizard

2 stars 1 forks source link

Improve custom file handling #19

Closed cpq closed 2 months ago

cpq commented 4 months ago

I have added a file containing a list of CA certificates in mongoose_fs.c to make it easier to handle TLS connections without requiring the specific CA cert be provided, and without needing to embed it in mongoose_glue.h. I have added a /web_root/logo.svg file to mongoose_fs.c to allow the browser to display a browser tab icon (like favicon.ico) (though on reflection I wonder if I could achieve that with css in the page properties? I'm sufficiently unfamiliar with how that all works to guess).

CA file for MQTT server, cert/key files for MQTT two-way auth, browser logo.

@dvosully should we display the logo set in the web ui editor as browser logo as well?

dvosully commented 4 months ago

@cpq Using the web ui editor logo as the browser logo would be a good start, but I think they may be different. The browser logo is rendered pretty small (in my case using the whole logo there is so small as to be entirely indistinguishable) but a smaller simpler logo (in my case an extract of the main logo) makes a good browser logo.

Regarding cert/key files for MQTT two-way auth, I would be keen for the API to maintain some way for user code to supply these if required, rather than embedding them into mongoose_fs.c and mongoose_impl.c - that would be problematic for any application where these get generated and loaded into the device by the end user. I'll supply details on that in a more relevant issue.

CA file is a bit different, because a generic list of CA certs can cover most public servers pretty easily.

cpq commented 2 months ago

Added UI logo uploading. TLS certs will be handled as a separate effort, since TLS is a somewhat different beast.