SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I came across something that I haven't ever needed, it's a file named: /etc/machine-id.
I see why it might be needed. So a couple of questions:
Firstly, I'm curious as to why it's not created on Slackware in /etc/machine-id during install (I like that this is the default, actually). And, secondly, what are the pros/cons of creating it manually, if needed?
I've used Slackware (currently 15.0) for many years and I'm pretty sure it's never been part of the install but I could be wrong, as I've never had a reason to use machine-id or go looking for it
Any comments, advice would be greatly appreciated.
Thanks everyone for responding! @Petri you are correct the file does indeed exist on my machine. Thank you that info. @BrianL lol I understand, point taken.
I was curious about this text in the doc referenced by Didier in particular - It "must" not be used "directly". Instead ...
"This ID uniquely identifies the host. It should be considered "confidential", and must not be exposed in untrusted environments, in particular on the network. If a stable unique identifier that is tied to the machine is needed for some application, the machine ID or any part of it must not be used directly. Instead the machine ID should be hashed with a cryptographic, keyed hash function, using a fixed, application-specific key. That way the ID will be properly unique, and derived in a constant way from the machine ID but there will be no way to retrieve the original machine ID from the application-specific one. "
Is *direct* application access to machine-id enforced by the system in anyway i.e. an application is only allowed access to the machine-id through sd_id128_get_machine* library calls or is it up to the application to do so but not required?
I have been experimenting with just some experimenting with rc.local_shutdown just replacing the content of /var/lib/dbus/machine-id via
uuidgen | tr -d '-' > /var/lib/dbus/machine-id
So far this does not seem to cause an issue. This might be a 'privacy enhanced' option for folks worried about it. It may be useful to have a globally unique machine identifier that isnt tied to any current network address for some applications for the life a user session.
It might be useful for that to persist beyond that but I think that should be clear choice presented user not a 'surprise' So I don't feel any remorse breaking the contract of the spec in this way. If that results in a broken application - well its probably not an application I want to be using.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.