Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: DataSnap UserAuthenticate


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 1 - Last Post: Apr 30, 2015 6:03 PM Last Post By: Natkunasingam J...
Natkunasingam J...

Posts: 57
Registered: 3/5/00
DataSnap UserAuthenticate  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 27, 2015 9:41 AM
In Delphi XE7 DataSnap REST (Stand-alone) Server

procedure TWebModule1.DSAuthenticationManager1UserAuthenticate

How do we get the UserAuthenticate returns False attempts from the client application, so that we can display Invalid login message to the user?

Regards,
Jeyan
Natkunasingam J...

Posts: 57
Registered: 3/5/00
Re: DataSnap UserAuthenticate  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 30, 2015 6:03 PM   in response to: Natkunasingam J... in response to: Natkunasingam J...
Natkunasingam Jeyakumar wrote:
In Delphi XE7 DataSnap REST (Stand-alone) Server

procedure TWebModule1.DSAuthenticationManager1UserAuthenticate

How do we get the UserAuthenticate returns False attempts from the client application, so that we can display Invalid login message to the user?

Regards,
Jeyan

Hi, My testing code as follows :

procedure TfrmClient.BtnLoginClick(Sender: TObject);
begin
 
try
 
  ClientModule1.Connect(EdtUsername.Text, EdtPassword.Text);
 
  //Invoke a server method to trigger UserAuthenticate - check valid login
  //ClientModule1.ServerMethods1Client.EchoString('test');
 
  TabControl2.ActiveTab := TabList;
  RefreshDataExecute(Sender);
 
except
  on E:Exception doShowMessage(E.message);
end;
 
end;


My issue is I am not getting any exception when connect attemps for the incorrect username/password.
but if I invoke a server method (as in commented lines in above code) I get exception as HTTP Error 403.14 - Forbidden.

Anything am I doing incorrect?

Regards,
Jeyan

Edited by: Natkunasingam Jeyakumar on Apr 30, 2015 6:03 PM
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02