On 11/14/2016 09:05 AM, Lennart Poettering wrote: > On Mon, 14.11.16 08:13, Stephen Gallagher (sgallagh@xxxxxxxxxx) wrote: > >> One way to address this might be for systemd to provide an API for what Lennart >> is suggesting and market that as "the correct way to generate a >> machine-id-derived string". >> >> Basically, I see the function looking something like: >> >> ``` >> const char * >> generate-machine-id(uint64_t app-specific-key, >> char *acceptable_chars, >> size_t num_characters) >> ``` >> (C example given, but probably we'd actually want this in D-BUS to be >> language-agnostic.) >> >> >> Then systemd can control the cryptographic hash. If this function exists and is >> public, then people will generally be inclined to use it and we will minimize >> the number of people who opt to try to write their own or use the machine-id >> directly. >> >> I will file an RFE. > > That sounds like a good idea, I think it would make a lot of sense for > libsystemd to expose an API to generate an app-specific machine > id. (though I'd stick to 128bit ids for both the app key and the result). https://github.com/systemd/systemd/issues/4667
Attachment:
signature.asc
Description: OpenPGP digital signature
_______________________________________________ devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx