AnsweredAssumed Answered

Restman update policy issue

Question asked by Naichun on Dec 14, 2017
Latest reply on Dec 19, 2017 by Naichun

Hello,

 

I have problem of updating CA API Gateway Policy

 

"url": "https://<ip>:9443/restman/1.0/policies/24e6fd7c5b6fb3a96690246c8ac492ec",

"method": "PUT",

"body":

<l7:Policy version="0" xmlns:l7="http://ns.l7tech.com/2010/04/gateway-management">
<l7:PolicyDetail version="0">
<l7:Name>#OTK OVP Configuration</l7:Name>
<l7:PolicyType>Include</l7:PolicyType>
<l7:Properties>
<l7:Property key="revision">
<l7:LongValue>1</l7:LongValue>
</l7:Property>
<l7:Property key="soap">
<l7:BooleanValue>false</l7:BooleanValue>
</l7:Property>
</l7:Properties>
</l7:PolicyDetail>
<l7:Resources>
<l7:ResourceSet tag="policy">
<l7:Resource type="policy">
<?xml version="1.0" encoding="UTF-8"?> <wsp:Policy xmlns:L7p="http://www.layer7tech.com/ws/policy" xmlns:wsp="http://schemas.xmlsoap.org/ws/2002/12/policy"> <wsp:All wsp:Usage="Required"> <L7p:CommentAssertion> <L7p:Comment stringValue="Target Configuration Policy: &quot;OTK OVP Configuration&quot;"/> </L7p:CommentAssertion> <L7p:CommentAssertion> <L7p:Comment stringValue="=== Set custom values for Context Variables below ==="/> </L7p:CommentAssertion> <L7p:CommentAssertion> <L7p:Comment stringValue="=== Add any new Context Variables or extensions below ==="/> </L7p:CommentAssertion> </wsp:All> </wsp:Policy>
</l7:Resource>
</l7:ResourceSet>
</l7:Resources>
</l7:Policy>

 

The error message is

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<l7:Error xmlns:l7="http://ns.l7tech.com/2010/04/gateway-management">
<l7:Type>BadRequest</l7:Type>
<l7:TimeStamp>2017-12-14T17:06:59.672-05:00</l7:TimeStamp>
<l7:Link rel="self" uri="https://*********:9443/restman/1.0/policies/24e6fd7c5b6fb3a96690246c8ac492ec"/>
<l7:Detail>HTTP 400 Bad Request. Caused by: The processing instruction target matching &quot;[xX][mM][lL]&quot; is not allowed.</l7:Detail>
</l7:Error>

 

Did I do anything wrong here?

 

Regards,

Naichun

Outcomes