Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: truncate /var/lib/dbus/machine-id in case it's separate from /etc/machine-id #1471

Merged
merged 1 commit into from
Feb 10, 2023

Conversation

cfm
Copy link
Contributor

@cfm cfm commented Feb 10, 2023

Signed-off-by: Cory Francis Myers [email protected]

Description

/var/lib/dbus/machine-id MAY be a symlink to /etc/machine-id. If it isn't, however, we need to truncate it separately to avoid reuse.

Related Issue

Fixes #1421.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Chore (non-breaking change that does not add functionality or fix an issue)

Checklist:

  • I have read the CONTRIBUTING document.
  • I have run the pre-merge tests locally and they pass.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • All commits have been signed-off for the Developer Certificate of Origin.

…/etc/machine-id"

"/var/lib/dbus/machine-id" MAY be a symlink to "/etc/machine-id".[1]  If it
isn't, however, we need to truncate it separately to avoid reuse.

Fixes chef#1421.

[1]: https://www.mail-archive.com/[email protected]/msg1818499.html

Signed-off-by: Cory Francis Myers <[email protected]>
@cfm cfm requested review from a team and Stromweld as code owners February 10, 2023 02:10
@sonarcloud
Copy link

sonarcloud bot commented Feb 10, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

Copy link
Collaborator

@Stromweld Stromweld left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice find, thanks for the PR

@Stromweld Stromweld merged commit 0c64148 into chef:main Feb 10, 2023
raykrist pushed a commit to norcams/bento that referenced this pull request Aug 19, 2024
…/etc/machine-id" (chef#1471)

"/var/lib/dbus/machine-id" MAY be a symlink to "/etc/machine-id".[1]  If it
isn't, however, we need to truncate it separately to avoid reuse.

Fixes chef#1421.

[1]: https://www.mail-archive.com/[email protected]/msg1818499.html

Signed-off-by: Cory Francis Myers <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

VMs from ubuntu-20.04 v202206.03.0 inherit a single machine-id, which breaks DHCP
2 participants