/** * @return a charset instance of the in use charset name. */ public Charset getCharset() { return Charset.forName(getCharsetName()); }
/** * @return a charset instance of the in use charset name. */ public Charset getCharset() { return Charset.forName(getCharsetName()); }
/** * Returns a charset instance of the in use charset name. */ public Charset getCharset() { return Charset.forName(getCharsetName()); }
/** * Encodes a HTTP request and sends it to the proxy server. * * @param nextFilter the next filter * @param request the http request */ private void writeRequest0(final NextFilter nextFilter, final HttpProxyRequest request) { try { String data = request.toHttpString(); IoBuffer buf = IoBuffer.wrap(data.getBytes(getProxyIoSession().getCharsetName())); LOGGER.debug(" write:\n{}", data.replace("\r", "\\r").replace("\n", "\\n\n")); writeData(nextFilter, buf); } catch (UnsupportedEncodingException ex) { closeSession("Unable to send HTTP request: ", ex); } }
/** * Encodes a HTTP request and sends it to the proxy server. * * @param nextFilter the next filter * @param request the http request */ private void writeRequest0(final NextFilter nextFilter, final HttpProxyRequest request) { try { String data = request.toHttpString(); IoBuffer buf = IoBuffer.wrap(data.getBytes(getProxyIoSession().getCharsetName())); LOGGER.debug(" write:\n{}", data.replace("\r", "\\r").replace("\n", "\\n\n")); writeData(nextFilter, buf); } catch (UnsupportedEncodingException ex) { closeSession("Unable to send HTTP request: ", ex); } }
/** * Encodes a HTTP request and sends it to the proxy server. * * @param nextFilter the next filter * @param request the http request */ private void writeRequest0(final NextFilter nextFilter, final HttpProxyRequest request) { try { String data = request.toHttpString(); IoBuffer buf = IoBuffer.wrap(data.getBytes(getProxyIoSession() .getCharsetName())); LOGGER.debug(" write:\n{}", data.replace("\r", "\\r").replace( "\n", "\\n\n")); writeData(nextFilter, buf); } catch (UnsupportedEncodingException ex) { closeSession("Unable to send HTTP request: ", ex); } }
hEntity = md5.digest(body.getBytes(proxyIoSession.getCharsetName()));
hEntity = md5.digest(body.getBytes(proxyIoSession.getCharsetName()));
md5.reset(); hEntity = md5.digest(body.getBytes(proxyIoSession .getCharsetName()));
proxyIoSession.getCharsetName())); } catch (IOException e) { throw new ProxyAuthException("Unable to decode the base64 encoded NTLM challenge", e);
String cnonce = new String(Base64.encodeBase64(nonce), proxyIoSession.getCharsetName()); map.put("cnonce", cnonce); } catch (UnsupportedEncodingException e) { map.put("response", DigestUtilities.computeResponseValue(proxyIoSession.getSession(), map, req .getHttpVerb().toUpperCase(), req.getProperties().get(HttpProxyConstants.PWD_PROPERTY), proxyIoSession.getCharsetName(), response.getBody()));
proxyIoSession.getCharsetName())); } catch (IOException e) { throw new ProxyAuthException("Unable to decode the base64 encoded NTLM challenge", e);
String cnonce = new String(Base64.encodeBase64(nonce), proxyIoSession.getCharsetName()); map.put("cnonce", cnonce); } catch (UnsupportedEncodingException e) { map.put("response", DigestUtilities.computeResponseValue(proxyIoSession.getSession(), map, req .getHttpVerb().toUpperCase(), req.getProperties().get(HttpProxyConstants.PWD_PROPERTY), proxyIoSession.getCharsetName(), response.getBody()));
String cnonce = new String(Base64 .encodeBase64(nonce), proxyIoSession .getCharsetName()); map.put("cnonce", cnonce); } catch (UnsupportedEncodingException e) { req.getProperties().get( HttpProxyConstants.PWD_PROPERTY), proxyIoSession.getCharsetName(), response .getBody()));
challengePacket = Base64 .decodeBase64(challengeResponse.substring(5).getBytes( proxyIoSession.getCharsetName())); } catch (IOException e) { throw new ProxyAuthException(
proxyIoSession.getCharsetName())); } catch (Exception e) { throw new ProxyAuthException("Parsing of server digest directives failed", e);
proxyIoSession.getCharsetName())); } catch (Exception e) { throw new ProxyAuthException("Parsing of server digest directives failed", e);
.substring(7).getBytes(proxyIoSession.getCharsetName())); } catch (Exception e) { throw new ProxyAuthException(