Logout

Alt-N Discussion Groups > MDaemon Discussion Groups > MDaemon API > XML API broken with 19.5.1?

 [F] Alt-N Discussion Groups  / MDaemon Discussion Groups  / MDaemon API  /

XML API broken with 19.5.1?

[nils.petersen@psyma.com]
nils.petersen@p…
Novice
Novice
Posts: 147
nils.petersen@psyma.com - 09:25am, Nov 13 2019

(reposting from mdbeta)

As it seems, the update from 19.5.0 to 19.5.1 broke the XML API.

We're using various automating functions (GetDomainList, GetUserInfo, SetDynamicScreen) and all of them just return an empty string.
Nothing shows up in the detail logs in \MDaemon\Logs\MdMgmtSW\ either.

Anyone using XML API and got it still working?

This PHP snippet used to work with 19.5.0:
define('MDAPIURL', 'https://mdlogtracker:xxxxxxxxxx@mail.psyma.com:3002/MdMgmtWS');

    $xml=
    '<?xml version="1.0" encoding="utf-8"?>
    <MDaemon>
        <API>
            <Request version="19.5.0" echo="1" verbose="1">
                <Operation>GetDomainList</Operation>
                <Parameters>
                    <Get>
                        <Users/>
                    </Get>
                </Parameters>
            </Request>
        </API>
    </MDaemon>';

    $ch = curl_init(MDAPIURL);
    curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: text/xml'));
    curl_setopt($ch, CURLOPT_POST, 1);
    curl_setopt($ch, CURLOPT_POSTFIELDS, $xml);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
    $response = curl_exec($ch);
    var_dump($response);
    curl_close($ch);

Regards
Nils



--MD-API-------------------------------------------------------------
This list is for questions and discussions regarding MDAEMON's API.
To unsubscribe from this mailing list send an email to
md-api-unsubscribe@mdaemon.com .
--POWERED BY MDAEMON!------------------------------------------------

---------------------------------------------------------------------
These forums are provided by MDaemon Technologies for user-to-user 
support and discussion.  MDaemon staff members may participate in the 
forums periodically but please recognize that this is not the official
method of receiving technical support. To receive personal technical 
support please use the form here:
http://www.mdaemon.com/support/request_support.asp
---------------------------------------------------------------------

  All MessagesOldest ItemsOlder ItemsNewer ItemsNewest Items

Keith Personett (apparently) - Nov 13, 2019 9:40 am (#1 Total: 13)  

via email  

Photo of Author
Keith Personett
Newbie
Newbie
Posts: 76

Nils,

 

What does the Logfile show?

 

Is Authentication succeeding? This sounds related to the authentication issue that we just implemented a fix for, where the client was not correctly sending the domain in the auth info…

 

Keith Personett

Senior Software Developer, Cerebro Calibration Specialist, Agent of S.H.I.E.LD., Helicarrier Systems Analyst

MDaemon Technologies http://www.mdaemon.com/ or on Facebook

Sent using Outlook 2013 via ActiveSync Services for MDaemon Messaging Server.

I 16 1018

"You get hurt, hurt 'em back. You get killed... walk it off!"

                - Steve Rogers/Captain America


--MD-API-------------------------------------------------------------
This list is for questions and discussions regarding MDAEMON's API.
To unsubscribe from this mailing list send an email to
md-api-unsubscribe@mdaemon.com .
--POWERED BY MDAEMON!------------------------------------------------

---------------------------------------------------------------------
These forums are provided by MDaemon Technologies for user-to-user 
support and discussion.  MDaemon staff members may participate in the 
forums periodically but please recognize that this is not the official
method of receiving technical support. To receive personal technical 
support please use the form here:
http://www.mdaemon.com/support/request_support.asp
---------------------------------------------------------------------

nils.petersen@psyma.com (apparently) - Nov 14, 2019 7:53 am (#2 Total: 13)  

via email  

Photo of Author
nils.petersen@p…
Novice
Novice
Posts: 147
Hi Keith,

On 13.11.2019 15:40, Keith Personett wrote:
What does the Logfile show?

which logfile do you mean? The MdMgmtWS-yyyy-mm-dd.log is empty apart from the rotation entries and has always been.

The DynScrn-yyyy-mm-dd.log used to show API usage entries like
191101 000100464 I [14A1715C] 0x41504000 Mgmt Logon: 172.16.9.110 [mdlogtracker@psyma.com] (MAIL1:mdmgmtws.dll:0B0C:079c)
191101 000100474 I [14A1715C] 0x4150400D Mgmt Add: Black Item: IP:95.211.209.158 (MDlogtracker SMTP pattern)
191101 000100482 I [14A1715C] 0x41504002 Mgmt Logoff: 172.16.9.110 [mdlogtracker@psyma.com]
but there's nothing like that any more since 19.5.1 was installed.

In \MDaemon\Logs\MdMgmtWS\ nothing shows up any more either - even failed requests used to be logged there.

Is Authentication succeeding?


I can't tell. Regardless of what I throw at the API it just returns an empty string, see the sample code. Unless authentication has been changed for the XML API it looks AOK to me.
HTTPS or HTTP doesn't make a difference either (to the configured RemoteAdmin ports 3002 or 3001 respectively).

This sounds related to the authentication issue that we just implemented a fix for, where the client was not correctly sending the domain in the auth info…


I think that's for ActiveSync - did anything else change as well?

Can you verify if the XML API works at all with 19.5.1, any which way? In the way our PHP script calls it? Is there any other way to do it?

Best!
Nils

--MD-API-------------------------------------------------------------
This list is for questions and discussions regarding MDAEMON's API.
To unsubscribe from this mailing list send an email to
md-api-unsubscribe@mdaemon.com .
--POWERED BY MDAEMON!------------------------------------------------

---------------------------------------------------------------------
These forums are provided by MDaemon Technologies for user-to-user 
support and discussion.  MDaemon staff members may participate in the 
forums periodically but please recognize that this is not the official
method of receiving technical support. To receive personal technical 
support please use the form here:
http://www.mdaemon.com/support/request_support.asp
---------------------------------------------------------------------



  (newer msg:11)All MessagesOldest ItemsOlder ItemsNewer ItemsNewest Items



 Content:

Read New | Search

 Guest:

Email to Admin



You are visiting as a Guest user.