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

[Bug]: Can't deploy CA policies with group exclusion #3614

Open
3 tasks done
TargetCrafter opened this issue Feb 11, 2025 · 6 comments
Open
3 tasks done

[Bug]: Can't deploy CA policies with group exclusion #3614

TargetCrafter opened this issue Feb 11, 2025 · 6 comments
Labels
bug Something isn't working unconfirmed-by-user

Comments

@TargetCrafter
Copy link

Required confirmations before submitting

  • I can reproduce this issue on the latest released versions of both CIPP and CIPP-API.
  • I have searched existing issues (both open and closed) to avoid duplicates.
  • I am not requesting general support; this is an actual bug report.

Issue Description

I can't deploy CA policies via the deployment tool when the CA policy has a group. It looks like the quotes are not correctly escaped when doing this.
Note that this word without a problem via te standards.

Image

  1. Setup a Template Library
  2. Create a CA policy with a group exclusion in the Library tenant
  3. Deploy the CA policy using either via the CA deployment tool
  4. Error

Environment Type

Sponsored (paying) user

Front End Version

7.1.3

Back End Version

7.1.3

Relevant Logs / Stack Trace


@TargetCrafter TargetCrafter added bug Something isn't working unconfirmed-by-user labels Feb 11, 2025
Copy link

Thank you for reporting a potential bug. If you would like to work on this bug, please comment:

I would like to work on this please!

Thank you for helping us maintain the project!

@KelvinTegelaar
Copy link
Owner

Cant seem to replicate this - Are you using 's in group names?

@TargetCrafter
Copy link
Author

TargetCrafter commented Feb 13, 2025

No, no quotes in the groups:

Group in the Template library tenant:

Image

Group Template in CIPP:

{
  "Displayname": "😊AwesomeGroup",
  "Description": "AwesomeGroup",
  "groupType": "dynamic",
  "MembershipRules": "(user.userPrincipalName -contains \\\"username\\\")",
  "allowExternal": null,
  "username": "AwesomeGroup",
  "GUID": "xxxxxx"
}

From the template in CIPP it looks like the "\" used to escape the quotes around the username is escaped with additional slashes. This means that after escaping all the characters in the string, there is still a slash remaining which causes the error.

@KelvinTegelaar
Copy link
Owner

I was looking at ca templates because of your description, but its groups. Checking this out :)

@TargetCrafter
Copy link
Author

My bad. We ran into the issue because we had to deploy the groups to be able to deploy CA policies that contain the group.

@JohnDuprey
Copy link
Collaborator

@TargetCrafter can you try to delete the group template and re-create it? We were unable to reproduce this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working unconfirmed-by-user
Projects
None yet
Development

No branches or pull requests

3 participants