Go4Expert

Go4Expert (http://www.go4expert.com/)
-   JSP (http://www.go4expert.com/forums/jsp/)
-   -   Implementing secure shell within JSP page (http://www.go4expert.com/forums/implementing-secure-shell-jsp-page-t29843/)

koustubh 29Sep2013 18:44

Implementing secure shell within JSP page
 
Hi,
I am new to JSP. I am trying to connect to my linux server through ssh from a JSP page, sing the library JSch. Please find attached the code and the error
</body>
</html>

org.apache.jasper.JasperException: Unable to compile class for JSP:

An error occurred at line: 17 in the jsp file: /Home-Transcode.jsp
JSch cannot be resolved to a type
14: <%@ page import="com.jcraft.jsch.*,java.io.*" %>
15: <%
16:
17: JSch shell = new JSch();
18:
19: %>
20: </body>


An error occurred at line: 17 in the jsp file: /Home-Transcode.jsp
JSch cannot be resolved to a type
14: <%@ page import="com.jcraft.jsch.*,java.io.*" %>
15: <%
16:
17: JSch shell = new JSch();
18:
19: %>
20: </body>


Stacktrace:
org.apache.jasper.compiler.DefaultErrorHandler.jav acError(DefaultErrorHandler.java:103)
org.apache.jasper.compiler.ErrorDispatcher.javacEr ror(ErrorDispatcher.java:366)
org.apache.jasper.compiler.JDTCompiler.generateCla ss(JDTCompiler.java:468)
org.apache.jasper.compiler.Compiler.compile(Compil er.java:378)
org.apache.jasper.compiler.Compiler.compile(Compil er.java:353)
org.apache.jasper.compiler.Compiler.compile(Compil er.java:340)
org.apache.jasper.JspCompilationContext.compile(Js pCompilationContext.java:646)
org.apache.jasper.servlet.JspServletWrapper.servic e(JspServletWrapper.java:357)
org.apache.jasper.servlet.JspServlet.serviceJspFil e(JspServlet.java:390)
org.apache.jasper.servlet.JspServlet.service(JspSe rvlet.java:334)
javax.servlet.http.HttpServlet.service(HttpServlet .java:728)


I think the library is correctly referenced as I can import the package without any problem. Could someone please help me with this?

Thanks,
Koustubh


All times are GMT +5.5. The time now is 07:58.