Skip to content

Consolidated profile#542

Merged
robertgendler merged 5 commits into
usnistgov:sequoiafrom
chkpnt:consolidated-profile
Sep 24, 2025
Merged

Consolidated profile#542
robertgendler merged 5 commits into
usnistgov:sequoiafrom
chkpnt:consolidated-profile

Conversation

@chkpnt
Copy link
Copy Markdown

@chkpnt chkpnt commented Aug 28, 2025

closes #536

Comment thread scripts/generate_guidance.py Outdated

consolidated_plist_file_path = os.path.join(settings_plist_output_path, f"{baseline_name}.plist")
with open(consolidated_plist_file_path, "wb") as consolidated_plist_file:
consolidated_profile.finalizeAndSavePlist(consolidated_plist_file)
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

This doesn't seem to work: It doesn't write a consolidated .plist file but seems to rewrite the previously written domain specific .plist files.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

The finalizeAndSavePlist function pulls out all of the settings from a configuration profile and writes the individual .plists for each preference domain. While the consolidated mobileconfig makes sense to me, I'm not sure a consolidated .plist file would be useful. Since .plists are applied to specific domains, having all of the domains in a single plist couldn't really be used.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I've removed these lines.

I have to admit that I'm still confused about the purpose of the domain specific plist files: The keys and values are already part of the corresponding mobileconfig files and the generated comliance script accesses only the .audit.plist file.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

The .plist files are generated for those that want to use something like the "Application and Custom Settings" payload in Jamf Pro. This let's you input .plist files into a configuration profile for Jamf Pro to deploy. Other MDMs also have the ability to deploy these managed preferences outside of their "supported" deployments.

The project outputs both to offer that flexibility.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewing the changes... the default_audit_plist function is no longer generating the default audit plist file that is used as an example for exemptions. I think it's due to the changes around line 880 or so. Is there a reason why you wanted to make those changes?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Actually, my mistake, i was looking at the incorrect output folder. You can ignore my last question.

Copy link
Copy Markdown
Collaborator

@brodjieski brodjieski left a comment

Choose a reason for hiding this comment

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

Rather than this being default behavior when generating profiles, can you add a new command line argument -P that will handle this generation?

@chkpnt
Copy link
Copy Markdown
Author

chkpnt commented Sep 9, 2025

Of course. Do you prefer -P to generate only the consolidated profile or in addition?

@brodjieski
Copy link
Copy Markdown
Collaborator

Of course. Do you prefer -P to generate only the consolidated profile or in addition?

I think we would want it as an additional option. So, for example, if someone only had -P it would only generate the consolidated profile. But if they passed both -p and -P it would output both the individual and combined profiles. This would give some flexibility to the current behavior while not introducing any unexpected outputs.

@chkpnt
Copy link
Copy Markdown
Author

chkpnt commented Sep 12, 2025

I didn't manage to finish the change this week; I'll do it next week.

@chkpnt chkpnt force-pushed the consolidated-profile branch from 77948dd to d8f2ecc Compare September 21, 2025 10:35
@robertgendler robertgendler merged commit c46f0cc into usnistgov:sequoia Sep 24, 2025
robertgendler added a commit that referenced this pull request Sep 24, 2025
robertgendler added a commit that referenced this pull request Sep 24, 2025
robertgendler added a commit that referenced this pull request Sep 24, 2025
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.

3 participants