?
Solved

return codes from com.ibm.os390.security.PlatformReturned

Posted on 2004-08-24
1
Medium Priority
?
493 Views
Last Modified: 2008-03-17
Hi,
   I need to use PlatformUser.authenticate method to authenticate users in RACF via a web page.  I need to display an error message when the userid or password is incorrect, and I also need to re-direct them to a different page when their password has expired.  I am trying to display the error codes from
PlatformReturned with the following simple code that I am using for testing:

String UserID = request.getParameter("UserID").trim().toUpperCase();
String Password = request.getParameter("PSWD").trim().toUpperCase();

PlatformReturned RACF_results = PlatformUser.authenticate(UserID, Password);
if (RACF_results == null) { out.println("Authentication successful"); }
else { out.println("RACF error = " + PlatformReturned.errno); }

but, I get the following error on the last line of code:

Can't make a static reference to nonstatic variable errno in class
com.ibm.os390.security.PlatformReturned.

Ultimately I just want to be able to determine if the userid or password is invalid and display a message, and redirect to a different page if the password has expired. Obviously I am going about this wrong and need help.

Thanks!



0
Comment
Question by:donz4
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 28

Accepted Solution

by:
rrz earned 600 total points
ID: 11882977
I don't know anything about   com.ibm.os390.security.PlatformReturned .
But, from the error message and the code you posted I will venture a guess.

>if (RACF_results == null) { out.println("Authentication successful"); }
Is that right ?  If success, then null is returned ?  So, if failure an object is returned ?
If, that is right then you should try  
else { out.println("RACF error = " + RACF_results.errno); }

rrz
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Check out the latest tech news, community articles, and expert highlights in August's newsletter.
This month, Experts Exchange’s free Course of the Month is focused on CompTIA IT Fundamentals.
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question