On 2/23/2011 4:18 PM, Joel wrote:
> >>> sackett-research-lab2b:~ joel$ sudo find /opt/Tomcat -type f -exec \
> >>>>   grep "function2.basiceng.umr.edu" "{}" \;
>
> Oops: I forgot the "-l" switch on grep... it's not giving you any file
> names :)


sackett-research-lab2b:~ joel$ sudo find /opt/Tomcat -type f -exec grep -l "
function2.basiceng.umr.edu" "{}" \;
Password:
Sorry, try again.
Password:
/opt/Tomcat/webapps/ROOT/index.jsp
/opt/Tomcat/webapps/view/acct_new.jsp
/opt/Tomcat/webapps/view/css/.nobar.css.swp
/opt/Tomcat/webapps/view/test.html
/opt/Tomcat/webapps/view/test1.html
/opt/Tomcat/webapps/view2/acct_new.jsp
/opt/Tomcat/webapps/view2/css/.nobar.css.swp
/opt/Tomcat/work/Standalone/localhost/_/index_jsp.class
/opt/Tomcat/work/Standalone/localhost/_/index_jsp.java
/opt/Tomcat/work/Standalone/localhost/view/acct_new_jsp.java





>  >>> Password:
> >>> <meta http-equiv="Refresh" content="0;url=
> >>> http://function2.basiceng.umr.edu/view";>
> >>> // "<a href=\"
> >>> http://function2.basiceng.umr.edu:8080/view/Accounting/confirm.jsp?id=";
> +
> >>> id + "\">"
> >>> Binary file /opt/Tomcat/webapps/view/css/.nobar.css.swp matches
> >>> <a href="http://function2.basiceng.umr.edu:8080/view/cgi-bin/test.cgi
> >>> ">Test</a>
> >>>  <FORM ACTION="http://function2.basiceng.umr.edu/tst.cgi";>
> >>> // "<a href=\"
> >>> http://function2.basiceng.umr.edu:8080/view/Accounting/confirm.jsp?id=";
> +
> >>> id + "\">"
> >>> Binary file /opt/Tomcat/webapps/view2/css/.nobar.css.swp matches
> >>> Binary file /opt/Tomcat/work/Standalone/localhost/_/index_jsp.class
> >>> matches
> >>>       out.write("<meta http-equiv=\"Refresh\" content=\"0;url=
> >>> http://function2.basiceng.umr.edu/view\";>\r\n");
> >>>  // "<a href=\"
> >>> http://function2.basiceng.umr.edu:8080/view/Accounting/confirm.jsp?id=";
> +
> >>> id + "\">"
>
> Got some hits, I see. What is the hostname of the server on which the
> app is actually running, now? Either :80 or :8080 should work given the
> configuration you've shown, so I suspect the hostname is the problem.
> You can always try to configure an /etc/hosts setting for the above
> hostname and set them to the IP address of the real host -- just for
> testing, of course... it's not reasonable to have users modify their
> hosts files just to use your webapp :)
>
> I'm not exactly sure what you are talking about. I don


I tried setting the host name to function2.basiceng.umr.edu with "sudo
scutil --set HostName function2.basiceng.umr.edu" I also tried escaping the
periods like so
"sudo scutil --set HostName "function2\.basiceng\.umr\.edu", and "sudo
scutil --set HostName function2\\.basiceng\\.umr\\.edu" and I tried putting
quotes around all of the former but the hostname continues to show up as
"function2" or "function2\".






function2:~ joel$ PS1="[\d \t \u@\h:\w ] $ "
[Thu Feb 24 13:19:21 joel@function2:~ ] $



I may be missing something here, if this isn't what you meant let me know.



>
> Hmm... does Wireshark have a Mac OS X build? You might try that if you
> get desperate.
>
> > So I was wondering if the website url in these files has anything to do
> with
> > my problem
>
> If the hostname of the server has changed (or you've moved the app,
> which it sounds like you have), then it is /very/ likely to cause problems.
>
>
Yes it does, but when I don



 > and if so are all the java files present for all the class files
>
> You'll have to check that out for yourself. How familiar are you with
> Java in general? Each .class file comes from a .java file, though there
> are some cases where the .java filename isn't obvious from the .class
> file name (inner classes, anonymous classes, and other assorted fun stuff).
>
> String constants are compiled-into the .class files without any
> compression, so if you have a .java file with that text in it, you
> should find it in the .java file that goes with it.
>
> Web applications rarely come with any source files in them, though .jsp
> files (which are compiled on the fly by the server) are always in
> "source form". If the webapp is written properly, all UI-related stuff
> will be in the .jsp files and not in any .java files.
>
> > and if so how would I go about recompiling the java files?
>
> That really depends on the build process of the webapp. Are there any
> files like "build.xml" in the root directory of the webapp? Anything
> else that might look like a build script? If you don't have any .java
> files, you have nothing to compile, which would be convenient. If you do
> have them and there are no build scripts, you might have to use "javac",
> the command-line compiler, which is similar to the "cc" C compiler
> except that it doesn't do any linking: just compiles .java -> .class.
>
> > Binary file Tomcat/work/Standalone/localhost/_/index_jsp.class matches
>
> These files are compiled .jsp files: you can ignore them and focus on
> the source .jsp with a similar name. For instance, the file above should
> have come from a file called "index.jsp".
>
> There will also be a .java file laying around with a similar name. Oh,
> there it is:
>
> > Tomcat/work/Standalone/localhost/_/index_jsp.java:      out.write("<meta
> > http-equiv=\"Refresh\" content=\"0;url=
> > http://function2.basiceng.umr.edu/view\";>\r\n");
>
>

Reply via email to