Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 205522 Details for
Bug 361365
401 html error page images don't load
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
fix
361365_1.txt (text/plain), 4.81 KB, created by
Malgorzata Janczarska
on 2011-10-19 09:04:03 EDT
(
hide
)
Description:
fix
Filename:
MIME Type:
Creator:
Malgorzata Janczarska
Created:
2011-10-19 09:04:03 EDT
Size:
4.81 KB
patch
obsolete
>diff --git a/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/FormAuthenticationService.java b/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/FormAuthenticationService.java >index bc9d014..c67f4a5 100644 >--- a/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/FormAuthenticationService.java >+++ b/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/FormAuthenticationService.java >@@ -90,11 +90,7 @@ public class FormAuthenticationService implements IAuthenticationService { > String xRequestedWith = req.getHeader("X-Requested-With"); //$NON-NLS-1$ > > if (version == null && !"XMLHttpRequest".equals(xRequestedWith)) { //$NON-NLS-1$ >- try { >- req.getRequestDispatcher("/loginstatic/LoginWindow.html").forward(req, resp); >- } catch (ServletException e) { >- LogHelper.log(new Status(IStatus.ERROR, Activator.PI_FORM_SERVLETS, 1, "An error occured during authenitcation", e)); >- } >+ resp.sendRedirect(req.getContextPath() + "/loginstatic/LoginWindow.html?redirect=" + req.getRequestURL()); > } else { > resp.setContentType("application/json; charset=UTF-8"); > JSONObject result = new JSONObject(); >diff --git a/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/servlets/LoginServlet.java b/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/servlets/LoginServlet.java >index dbd7e2e..3009ba5 100644 >--- a/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/servlets/LoginServlet.java >+++ b/bundles/org.eclipse.orion.server.authentication.form/src/org/eclipse/orion/server/authentication/form/servlets/LoginServlet.java >@@ -101,8 +101,7 @@ public class LoginServlet extends HttpServlet { > > if (version == null && !"XMLHttpRequest".equals(xRequestedWith)) { //$NON-NLS-1$ > //RequestDispatcher rd = req.getRequestDispatcher("/loginform?error=" + new String(Base64.encode(invalidLoginError.getBytes()))); //$NON-NLS-1$ >- RequestDispatcher rd = req.getRequestDispatcher("/loginstatic/LoginWindow.html"); >- rd.include(req, resp); >+ resp.sendRedirect(req.getContextPath() + "/loginstatic/LoginWindow.html"); > } else { > resp.setStatus(HttpServletResponse.SC_UNAUTHORIZED); > PrintWriter writer = resp.getWriter(); >diff --git a/bundles/org.eclipse.orion.server.authentication.formopenid/src/org/eclipse/orion/server/authentication/formopenid/FormOpenIdAuthenticationService.java b/bundles/org.eclipse.orion.server.authentication.formopenid/src/org/eclipse/orion/server/authentication/formopenid/FormOpenIdAuthenticationService.java >index 3b9a6d4..ada8295 100644 >--- a/bundles/org.eclipse.orion.server.authentication.formopenid/src/org/eclipse/orion/server/authentication/formopenid/FormOpenIdAuthenticationService.java >+++ b/bundles/org.eclipse.orion.server.authentication.formopenid/src/org/eclipse/orion/server/authentication/formopenid/FormOpenIdAuthenticationService.java >@@ -79,7 +79,7 @@ public class FormOpenIdAuthenticationService implements IAuthenticationService { > > private void setNotAuthenticated(HttpServletRequest req, HttpServletResponse resp, Properties properties) throws IOException { > resp.setHeader("WWW-Authenticate", HttpServletRequest.FORM_AUTH); //$NON-NLS-1$ >- resp.setStatus(HttpServletResponse.SC_UNAUTHORIZED); >+ resp.setStatus(HttpServletResponse.SC_UNAUTHORIZED); > > // redirection from FormAuthenticationService.setNotAuthenticated > String versionString = req.getHeader("Orion-Version"); //$NON-NLS-1$ >@@ -90,11 +90,7 @@ public class FormOpenIdAuthenticationService implements IAuthenticationService { > String xRequestedWith = req.getHeader("X-Requested-With"); //$NON-NLS-1$ > > if (version == null && !"XMLHttpRequest".equals(xRequestedWith)) { //$NON-NLS-1$ >- try { >- req.getRequestDispatcher("/mixloginstatic/LoginWindow.html").forward(req, resp); >- } catch (ServletException e) { >- LogHelper.log(new Status(IStatus.ERROR, Activator.PI_FORMOPENID_SERVLETS, 1, "An error occured during authenitcation", e)); >- } >+ resp.sendRedirect(req.getContextPath() + "/mixloginstatic/LoginWindow.html?redirect=" + req.getRequestURI()); > } else { > resp.setContentType(ProtocolConstants.CONTENT_TYPE_JSON); > JSONObject result = new JSONObject(); >@@ -104,7 +100,7 @@ public class FormOpenIdAuthenticationService implements IAuthenticationService { > } catch (JSONException e) { > LogHelper.log(new Status(IStatus.ERROR, Activator.PI_FORMOPENID_SERVLETS, 1, "An error occured during authenitcation", e)); > } >- resp.getWriter().print(result.toString()); >+ resp.getWriter().print(result.toString()); > } > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 361365
:
205516
|
205522
|
205542