Add license to policy-engine files
[policy/engine.git] / POLICY-SDK-APP / src / test / resources / Config_PM_TestClosedLoopPMPolicy.1.xml
1 <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2 <!--
3   ============LICENSE_START==================================================
4   ONAP Policy Engine
5   ===========================================================================
6   Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved.
7   ===========================================================================
8   Licensed under the Apache License, Version 2.0 (the "License");
9   you may not use this file except in compliance with the License.
10   You may obtain a copy of the License at
11   
12        http://www.apache.org/licenses/LICENSE-2.0
13   
14   Unless required by applicable law or agreed to in writing, software
15   distributed under the License is distributed on an "AS IS" BASIS,
16   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17   See the License for the specific language governing permissions and
18   limitations under the License.
19   ============LICENSE_END====================================================
20   -->
21  <Policy xmlns="urn:oasis:names:tc:xacml:3.0:core:schema:wd-17" PolicyId="urn:xacml:policy:id:a3ff3c48-b16f-436a-9aaa-ac7a3515b0e8" Version="1" RuleCombiningAlgId="urn:oasis:names:tc:xacml:3.0:rule-combining-algorithm:permit-overrides">
22      <Description>TestClosedLoopPMPolicy@CreatedBy:rb7147@CreatedBy:@ModifiedBy:rb7147@ModifiedBy:</Description>
23      <Target>
24          <AnyOf>
25              <AllOf>
26                  <Match MatchId="org.onap.function.regex-match">
27                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">com.Config_PM_TestClosedLoopPMPolicy.1.xml</AttributeValue>
28                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:1.0:subject-category:access-subject" AttributeId="PolicyName" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
29                  </Match>
30              </AllOf>
31              <AllOf>
32                  <Match MatchId="org.onap.function.regex-match">
33                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">Test</AttributeValue>
34                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:1.0:subject-category:access-subject" AttributeId="ONAPName" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
35                  </Match>
36                  <Match MatchId="org.onap.function.regex-match">
37                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">SampleRiskType</AttributeValue>
38                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" AttributeId="RiskType" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
39                  </Match>
40                  <Match MatchId="org.onap.function.regex-match">
41                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">1</AttributeValue>
42                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" AttributeId="RiskLevel" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
43                  </Match>
44                  <Match MatchId="org.onap.function.regex-match">
45                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">True</AttributeValue>
46                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" AttributeId="guard" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
47                  </Match>
48                  <Match MatchId="org.onap.function.regex-match">
49                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">08-06-2017</AttributeValue>
50                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" AttributeId="TTLDate" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
51                  </Match>
52                  <Match MatchId="org.onap.function.regex-match">
53                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">Registration Failure(Trinity)</AttributeValue>
54                      <AttributeDesignator Category="urn:oasis:names:tc:xacml:1.0:subject-category:access-subject" AttributeId="ServiceType" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
55                  </Match>
56              </AllOf>
57          </AnyOf>
58      </Target>
59      <Rule RuleId="" Effect="Permit">
60          <Target>
61              <AnyOf>
62                  <AllOf>
63                      <Match MatchId="urn:oasis:names:tc:xacml:3.0:function:string-equal-ignore-case">
64                          <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">ACCESS</AttributeValue>
65                          <AttributeDesignator Category="urn:oasis:names:tc:xacml:3.0:attribute-category:action" AttributeId="urn:oasis:names:tc:xacml:1.0:action:action-id" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
66                      </Match>
67                      <Match MatchId="urn:oasis:names:tc:xacml:3.0:function:string-equal-ignore-case">
68                          <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">Config</AttributeValue>
69                          <AttributeDesignator Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" AttributeId="urn:oasis:names:tc:xacml:1.0:resource:resource-id" DataType="http://www.w3.org/2001/XMLSchema#string" MustBePresent="false"/>
70                      </Match>
71                  </AllOf>
72              </AnyOf>
73          </Target>
74          <AdviceExpressions>
75              <AdviceExpression AdviceId="PMID" AppliesTo="Permit">
76                  <AttributeAssignmentExpression AttributeId="type" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
77                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">Configuration</AttributeValue>
78                  </AttributeAssignmentExpression>
79                  <AttributeAssignmentExpression AttributeId="URLID" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
80                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#anyURI">$URL/Config/com.Config_PM_TestClosedLoopPMPolicy.1.json</AttributeValue>
81                  </AttributeAssignmentExpression>
82                  <AttributeAssignmentExpression AttributeId="PolicyName" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
83                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">com.Config_PM_TestClosedLoopPMPolicy.1.xml</AttributeValue>
84                  </AttributeAssignmentExpression>
85                  <AttributeAssignmentExpression AttributeId="VersionNumber" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
86                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">1</AttributeValue>
87                  </AttributeAssignmentExpression>
88                  <AttributeAssignmentExpression AttributeId="matching:ONAPName" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
89                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">Test</AttributeValue>
90                  </AttributeAssignmentExpression>
91                  <AttributeAssignmentExpression AttributeId="matching:ServiceType" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
92                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">Registration Failure(Trinity)</AttributeValue>
93                  </AttributeAssignmentExpression>
94                  <AttributeAssignmentExpression AttributeId="RiskType" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
95                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">SampleRiskType</AttributeValue>
96                  </AttributeAssignmentExpression>
97                  <AttributeAssignmentExpression AttributeId="RiskLevel" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
98                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">1</AttributeValue>
99                  </AttributeAssignmentExpression>
100                  <AttributeAssignmentExpression AttributeId="guard" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
101                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">True</AttributeValue>
102                  </AttributeAssignmentExpression>
103                  <AttributeAssignmentExpression AttributeId="TTLDate" Category="urn:oasis:names:tc:xacml:3.0:attribute-category:resource" Issuer="">
104                      <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">08-06-2017</AttributeValue>
105                  </AttributeAssignmentExpression>
106              </AdviceExpression>
107          </AdviceExpressions>
108      </Rule>
109  </Policy>