Thank you for your responses. I think my question wasn't exact enough.
I solved my problem using iframe with first applications's login page as a source.
<iframe id = "iframe1" name ="loginFrame" src="http://domain2/Login.aspx?for_web=true" onload="iframeLoaded" ></iframe>
To redirect to the logged-in default page of the first site, added OnClientClick="formWeb.target ='_parent';" to a login button. So when the Login button is clicked, in case of successful authentication, the default page (under another domain) will be opened in the same window (not a frame)
<form id="formWeb" runat="server">
<asp:Button ID="btnLogin" runat="server" Text="Login" OnClick="btnLogin_Click" OnClientClick="formWeb.target ='_parent';" />
</form>