<def-group>
    <definition class="compliance" id="{{{ rule_id }}}" version="1">
           {{{ oval_metadata("SSSD should be configured to map the certificate to
            correct user or group", rule_title=rule_title) }}}
        <criteria>
            <criterion comment="check value of ldap_user_certificate in sssd configuration"
                       test_ref="test_{{{rule_id}}}" />
        </criteria>
    </definition>

    <ind:textfilecontent54_test check="all" check_existence="all_exist" comment="test the value of
        ldap_user_certificate in sssd configuration" id="test_{{{rule_id}}}" version="1">
        <ind:object object_ref="obj_{{{rule_id}}}" />
        <ind:state state_ref="state_{{{rule_id}}}" />
    </ind:textfilecontent54_test>

    <ind:textfilecontent54_object id="obj_{{{rule_id}}}" version="1">
        <ind:filepath>/etc/sssd/sssd.conf</ind:filepath>
        <ind:pattern operation="pattern match">^[\s]*\[[^\n\[\]]+\](?:[^\n\[]*\n+)+?[\s]*ldap_user_certificate\s*=\s*([\w;]+)$</ind:pattern>
        <ind:instance operation="greater than or equal" datatype="int">1</ind:instance>
    </ind:textfilecontent54_object>

    <ind:textfilecontent54_state comment="value of ldap_user_certificate" id="state_{{{rule_id}}}" version="1">
        <ind:subexpression operation="equals">userCertificate;binary</ind:subexpression>
    </ind:textfilecontent54_state>
</def-group>
