Okay, first, a little muddying of the waters...
I'm running this in Apache 1.3.27 and Tomcat 4.1.29 and Oracle 4.2.0.4. What it is is a small collection of jsp scripts that authenticate a user (vs the local machine) and then show their usage for a given time (from the scripts) with the data pulled from oracle. right now, everything is on the local machine. i'm trying to change that. i want the scripts to be on one machine, the authentication on another, and oracle on yet a third (for right now, i'll settle for authentication and oracle on the same box so long as it is different the the box serving up the web pages). I posted this to the tomcat list and they suggested getting ahold of someone in the fusebox community.
java.lang.UnsatisfiedLinkError: checkUser
at FuseBoxServlet.checkUser(Native Method)
at FuseBoxServlet.doGet(FuseBoxServlet.java:40)
at FuseBoxServlet.doPost(FuseBoxServlet.java:9)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
the following is my FuseBoxServlet.java (which to me looks "homemade" but?) other than a lot of bouncing around different places saying the work on fusebox i know nothing about it.
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
public class FuseBoxServlet extends HttpServlet {
public void doPost(HttpServletRequest req, HttpServletResponse res)
throws IOException, ServletException {
doGet(req, res);
}
public void doGet(HttpServletRequest req, HttpServletResponse res)
throws IOException, ServletException {
String userName = req.getParameter("username");
String userPass = req.getParameter("password");
String action = ""> RequestDispatcher rd = null;
HttpSession session = null;
session = req.getSession(true);
if(session.getAttribute("logon.correct")!=null) {
if(action!=null && (action.equals("logoff") || action.equals("logout"))) { session.invalidate();
rd = req.getRequestDispatcher("/login.jsp");
rd.forward(req, res);
} else if(action!=null && action.equals("get_report")) {
//forward to the report generating servlet
rd = req.getRequestDispatcher("/get_report");
rd.forward(req, res);
} else {
rd = req.getRequestDispatcher("/main.jsp");
rd.forward(req, res);
}
} else {
if((userName==null || userPass==null)) {
//wrong!
rd = req.getRequestDispatcher("/login.jsp");
rd.forward(req, res);
} else {
if(checkUser(userName, userPass)) {
//credentials correct -- login user
session = req.getSession(true);
session.setAttribute("logon.correct", userName);
rd = req.getRequestDispatcher("/main.jsp");
rd.forward(req, res);
} else {
req.setAttribute("login.incorrect", new Boolean(true));
rd = req.getRequestDispatcher("/login.jsp");
rd.forward(req, res);
}
}
}
}//end of doGet()
static {
try {
System.loadLibrary("auth");
} catch (UnsatisfiedLinkError er) {
System.out.println("Error loading Shared library: " +
er.getMessage());
}
}//end of static block
public native boolean checkUser(String username, String password);
}//end of class
i've looked at the fusebox FAQ on fusebox.org and i think i'm more lost now than i was this morning. any help, links, slaps accross the face followed by being told to wake up; will be much appreciated.
Thank you
t-
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
