aboutsummaryrefslogtreecommitdiff
path: root/id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java
diff options
context:
space:
mode:
authorThomas Lenz <tlenz@iaik.tugraz.at>2016-09-30 09:22:29 +0200
committerThomas Lenz <tlenz@iaik.tugraz.at>2016-09-30 09:22:29 +0200
commitd025c38a426e22b0d1ccfbb4558ff6ce78ac1d0b (patch)
tree6bd538b3faab08ecec07c1fcff47e4c84f483b47 /id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java
parent5dda0359afcdc69b11bc9a8df5c527e6c1488b6f (diff)
downloadmoa-id-spss-d025c38a426e22b0d1ccfbb4558ff6ce78ac1d0b.tar.gz
moa-id-spss-d025c38a426e22b0d1ccfbb4558ff6ce78ac1d0b.tar.bz2
moa-id-spss-d025c38a426e22b0d1ccfbb4558ff6ce78ac1d0b.zip
refactor http servlet response processing to prohibit 'chunked' transfer encoding
Diffstat (limited to 'id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java')
-rw-r--r--id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java b/id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java
index 0f17eccab..22ac37604 100644
--- a/id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java
+++ b/id/server/modules/moa-id-module-eIDAS/src/main/java/at/gv/egovernment/moa/id/protocols/eidas/eIDASAuthenticationRequest.java
@@ -252,8 +252,11 @@ public class eIDASAuthenticationRequest implements IAction {
Logger.trace("Sending html content : " + new String(writer.getBuffer()));
- httpResp.getOutputStream().write(writer.getBuffer().toString().getBytes("UTF-8"));
+ byte[] content = writer.getBuffer().toString().getBytes("UTF-8");
httpResp.setContentType(MediaType.TEXT_HTML.getType());
+ httpResp.setContentLength(content.length);
+ httpResp.getOutputStream().write(content);
+
} catch (Exception e) {
Logger.error("Velocity error: " + e.getMessage());