final String casServiceUrl = URLEncoder.encode(PropertiesManager .getProperty("cas.serviceUrl"), URL_ENCODING);
final String casServiceUrl = URLEncoder.encode(CASServiceUrlProvider .getServiceUrl(requestURL), URL_ENCODING);
    private CASReceipt getCASReceipt(final String casTicket) throws ExcepcaoAutenticacao {        CASReceipt receipt = null;        try {            final String casValidateUrl = PropertiesManager.getProperty("cas.validateUrl");            final String casServiceUrl = URLEncoder.encode(PropertiesManager                    .getProperty("cas.serviceUrl"), URL_ENCODING);            ProxyTicketValidator pv = new ProxyTicketValidator();            pv.setCasValidateUrl(casValidateUrl);            pv.setServiceTicket(casTicket);            pv.setService(casServiceUrl);            pv.setRenew(false);            receipt = CASReceipt.getReceipt(pv);        } catch (UnsupportedEncodingException e) {            throw new RuntimeException(e);        } catch (CASAuthenticationException e) {            throw new ExcepcaoAutenticacao("bad.authentication", e);        }        return receipt;    }