Am 11.12.24 um 10:24 schrieb Daniel Kral: > As the initial use case for the first boot feature request [0] was for > running shell scripts, the auto installer retrieved the binary as a > `String`. Unfortunately, this tries to interpret binary data as UTF-8 > and will transform 'invalid' characters to replacement characters [1]. > > This causes the auto-installer to create an invalid binary when fetching > from an URL, and error with a `stream did not contain valid UTF-8` error > when fetching from the ISO image. > > To allow binary executables to be used as a first boot executable, this > commit changes the fetching from being read as a `String` to being read > as a `Vec<u8>` to not interfere with the content of the executable. > > [0] https://bugzilla.proxmox.com/show_bug.cgi?id=5579 > [1] https://doc.rust-lang.org/src/alloc/string.rs.html#635 > > Signed-off-by: Daniel Kral <d.k...@proxmox.com> > --- > changes from v1: > - remove explicit handling of `std::io::ErrorKind::UnexpectedEof` > > .../src/bin/proxmox-auto-installer.rs | 12 ++++++++---- > proxmox-installer-common/src/http.rs | 18 ++++++++++++++---- > 2 files changed, 22 insertions(+), 8 deletions(-) > >
applied, with Christoph's R-b and T-b, thanks! _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel