This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

API Rule Group Endpoint

I've been working with the Sophos XG Firewall XML API and so far I've been unable to access the firewall rule group endpoint that is defined in the docs.

My request xmlreq parameter looks like this:

<Request>
<Login>
<Username>admin</Username>
<Password>sadfjiojO8AUOFDSJ!</Password>
</Login>
<Get>
<FirewallRuleGroup>
</FirewallRuleGroup>
</Get>
</Request>

This is the response I got:

<?xml version="1.0" encoding="UTF-8"?>
<Response APIVersion="1702.1" IPS_CAT_VER="1">
<Login>
<status>Authentication Successful</status>
</Login>
<RuleGroup>
<Status code="529">Input request module is Invalid</Status>
</RuleGroup>
</Response>


Process finished with exit code 0



This thread was automatically locked due to age.
Parents
  • Which version of SFOS are you trying this on? I think you need the APIVersion in your request.


    <Request APIVersion="1800.1">

    <Login>

    <Username>admin</Username>

    <Password>secretsquirrel</Password>

    </Login>

    <Get>

    <FirewallRuleGroup>

    </FirewallRuleGroup>

    </Get>

    </Request>

    <?xml version="1.0" encoding="UTF-8"?>
    <Response APIVersion="1800.1" IPS_CAT_VER="1">
    <Login>
    <status>Authentication Successful</status>
    </Login>
    <FirewallRuleGroup transactionid="">
    <Status>No. of records Zero.</Status>
    </FirewallRuleGroup>
    </Response>
  • I've put 1702.1 as the API version as well (in quotes) and it gave me the same error from the start

  • Can you post this in a web browser and tell me what response you get. Obviously change IP and password for yours.

    192.168.0.1:4444/.../APIController APIVersion="1702.1"><Login><Username>admin</Username><Password>secretsquirrel</Password></Login><Get> <FirewallRuleGroup></FirewallRuleGroup> </Get></Request>

  • I actually just tried the request again without the API version and it also returns a response

    192.168.0.1:4444/.../APIController <FirewallRuleGroup></FirewallRuleGroup> </Get></Request>

    <?xml version="1.0" encoding="UTF-8"?>
    <Response APIVersion="1800.2" IPS_CAT_VER="1">
    <Login>
    <status>Authentication Successful</status>
    </Login>
    <FirewallRuleGroup transactionid="">
    <Status>No. of records Zero.</Status>
    </FirewallRuleGroup>
    </Response>
Reply
  • I actually just tried the request again without the API version and it also returns a response

    192.168.0.1:4444/.../APIController <FirewallRuleGroup></FirewallRuleGroup> </Get></Request>

    <?xml version="1.0" encoding="UTF-8"?>
    <Response APIVersion="1800.2" IPS_CAT_VER="1">
    <Login>
    <status>Authentication Successful</status>
    </Login>
    <FirewallRuleGroup transactionid="">
    <Status>No. of records Zero.</Status>
    </FirewallRuleGroup>
    </Response>
Children
No Data