/*************************************************************************** roamingservice.cpp - description ------------------- begin : sun Jan 4 2009 copyright : (C) 2009 by Antonio Nastasi email : sifcenter(at)gmail.com ***************************************************************************/ /*************************************************************************** * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * ***************************************************************************/ #include "roamingservice.h" #include "soapmessage.h" #include "../../utils/kmessshared.h" #include "../../kmessdebug.h" /** * @brief URL of the Storage Service */ #define SERVICE_URL_STORAGE_SERVICE "https://storage.msn.com/storageservice/SchematizedStore.asmx" RoamingService::RoamingService( QObject *parent ) : PassportLoginService( parent ) { } RoamingService::~RoamingService() { } QString RoamingService::createCommonHeader() const { QString header( "<StorageApplicationHeader xmlns=\"http://www.msn.com/webservices/storage/w10\">\n" "<ApplicationID>Messenger Client 8.5</ApplicationID>\n" "<Scenario>RoamingSeed</Scenario>\n" "</StorageApplicationHeader>\n" "<StorageUserHeader xmlns=\"http://www.msn.com/webservices/storage/w10\">\n" "<Puid>0</Puid>\n" "<TicketToken />\n" // Filled in by the base class "</StorageUserHeader>\n" ); return header; } void RoamingService::getProfile( const QString& cid ) { QString body( "<GetProfile xmlns=\"http://www.msn.com/webservices/storage/w10\">\n" "<profileHandle>\n" "<Alias>\n" "<Name>" + cid +"</Name>\n" "<NameSpace>MyCidStuff</NameSpace>\n" "</Alias>\n" "<RelationshipName>MyProfile</RelationshipName>\n" "</profileHandle>\n" "<profileAttributes>\n" "<ResourceID>true</ResourceID>\n" "<DateModified>true</DateModified>\n" "<ExpressionProfileAttributes>\n" "<ResourceID>true</ResourceID>\n" "<DateModified>true</DateModified>\n" "<DisplayName>true</DisplayName>\n" "<DisplayNameLastModified>true</DisplayNameLastModified>\n" "<PersonalStatus>true</PersonalStatus>\n" "<PersonalStatusLastModified>true</PersonalStatusLastModified>\n" "<StaticUserTilePublicURL>true</StaticUserTilePublicURL>\n" "<Photo>true</Photo>\n" "<Flags>true</Flags>\n" "</ExpressionProfileAttributes>\n" "</profileAttributes>\n" "</GetProfile>\n" ); sendSecureRequest( new SoapMessage( SERVICE_URL_STORAGE_SERVICE, "http://www.msn.com/webservices/storage/w10/GetProfile", createCommonHeader(), body ), "Storage" ); } // Parse the SOAP fault 00097 void RoamingService::parseSecureFault( SoapMessage *message ) { Q_UNUSED( message ); } // The connection received the full response 00105 void RoamingService::parseSecureResult( SoapMessage *message ) { Q_UNUSED( message ); } #include "roamingservice.moc"