Skip to content

machine-id discrepancy in --help and what it actually does? #4689

Answered by kmk3
svc88 asked this question in Q&A
Discussion options

You must be logged in to vote

@svc88 on Nov 15:

Its been stated in the firejail --help section -> --machine-id - preserve
/etc/machine-id So if using machine-id preserves the real /etc/machine-id
then why when actually using it does it randomize it? Also talked about
under: https://firejail.wordpress.com/2021/01/21/firejail-tips-and-tricks/
that it randomizes the machine id.

This is what it does:

// spoof /etc/machine_id
void fs_machineid(void) {
	union machineid_t {
		uint8_t u8[16];
		uint32_t u32[4];
	} mid;

	// if --machine-id flag is inactive, do nothing
	if (arg_machineid == 0)
		return;
	if (arg_debug)
		printf("Generating a new machine-id\n");

From the current firejail(1) man page:

--machine-id
       Spoof…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@kmk3
Comment options

@svc88
Comment options

@kmk3
Comment options

Answer selected by kmk3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
documentation Issues and pull requests related to the documentation
2 participants