Skip to content

Commit bfae2a4

Browse files
committed
Switch embedded content to uint8_t and add gzip flag
Convert embedded HTTP content arrays from const char to uint8_t for safe binary handling, update FilesContent.content type accordingly, and add a gzip boolean to FilesContent. Update kHttpContent entries to include the new gzip field (set to false) and regenerate the embedded content binary. This allows distinguishing compressed content and ensures correct handling of non-text bytes.
1 parent da62c32 commit bfae2a4

33 files changed

Lines changed: 84 additions & 83 deletions

lib-remoteconfig/http/content/common.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char common_js[] = {
1+
static constexpr uint8_t common_js[] = {
22
0x66, 0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x20, 0x24, 0x28, 0x69, 0x64, 0x29, 0x20, 0x7B,
33
0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6E, 0x20, 0x64, 0x6F, 0x63, 0x75, 0x6D, 0x65, 0x6E, 0x74,
44
0x2E, 0x67, 0x65, 0x74, 0x45, 0x6C, 0x65, 0x6D, 0x65, 0x6E, 0x74, 0x42, 0x79, 0x49, 0x64, 0x28,

lib-remoteconfig/http/content/config_artnet.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_artnet_js[] = {
1+
static constexpr uint8_t config_artnet_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x61, 0x72, 0x74, 0x6E, 0x65, 0x74, 0x20, 0x3D, 0x20,
33
0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20, 0x66, 0x75,
44
0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E, 0x61, 0x6D,

lib-remoteconfig/http/content/config_display.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_display_js[] = {
1+
static constexpr uint8_t config_display_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x64, 0x69, 0x73, 0x70, 0x6C, 0x61, 0x79, 0x20, 0x3D,
33
0x20, 0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20, 0x66,
44
0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E, 0x61,

lib-remoteconfig/http/content/config_dmxmonitor.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_dmxmonitor_js[] = {
1+
static constexpr uint8_t config_dmxmonitor_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x64, 0x6D, 0x78, 0x6D, 0x6F, 0x6E, 0x69, 0x74, 0x6F,
33
0x72, 0x20, 0x3D, 0x20, 0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E,
44
0x63, 0x20, 0x66, 0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C,

lib-remoteconfig/http/content/config_dmxnode.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_dmxnode_js[] = {
1+
static constexpr uint8_t config_dmxnode_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x64, 0x6D, 0x78, 0x6E, 0x6F, 0x64, 0x65, 0x20, 0x3D,
33
0x20, 0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20, 0x66,
44
0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E, 0x61,

lib-remoteconfig/http/content/config_dmxpca9685.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_dmxpca9685_js[] = {
1+
static constexpr uint8_t config_dmxpca9685_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x64, 0x6D, 0x78, 0x70, 0x63, 0x61, 0x39, 0x36, 0x38,
33
0x35, 0x20, 0x3D, 0x20, 0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E,
44
0x63, 0x20, 0x66, 0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C,

lib-remoteconfig/http/content/config_dmxpixel.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_dmxpixel_js[] = {
1+
static constexpr uint8_t config_dmxpixel_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x64, 0x6D, 0x78, 0x70, 0x69, 0x78, 0x65, 0x6C, 0x20,
33
0x3D, 0x20, 0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20,
44
0x66, 0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E,

lib-remoteconfig/http/content/config_dmxsend.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_dmxsend_js[] = {
1+
static constexpr uint8_t config_dmxsend_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x64, 0x6D, 0x78, 0x73, 0x65, 0x6E, 0x64, 0x20, 0x3D,
33
0x20, 0x7B, 0x0A, 0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20, 0x66,
44
0x75, 0x6E, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E, 0x61,

lib-remoteconfig/http/content/config_e131.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_e131_js[] = {
1+
static constexpr uint8_t config_e131_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x65, 0x31, 0x33, 0x31, 0x20, 0x3D, 0x20, 0x7B, 0x0A,
33
0x69, 0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20, 0x66, 0x75, 0x6E, 0x63,
44
0x74, 0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E, 0x61, 0x6D, 0x65, 0x29,

lib-remoteconfig/http/content/config_etc.js.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static constexpr char config_etc_js[] = {
1+
static constexpr uint8_t config_etc_js[] = {
22
0x77, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x2E, 0x65, 0x74, 0x63, 0x20, 0x3D, 0x20, 0x7B, 0x0A, 0x69,
33
0x6E, 0x69, 0x74, 0x3A, 0x20, 0x61, 0x73, 0x79, 0x6E, 0x63, 0x20, 0x66, 0x75, 0x6E, 0x63, 0x74,
44
0x69, 0x6F, 0x6E, 0x28, 0x70, 0x61, 0x74, 0x68, 0x2C, 0x20, 0x6E, 0x61, 0x6D, 0x65, 0x29, 0x20,

0 commit comments

Comments
 (0)