Migrating RestTemplate with digest Authentication from httpclient (4.x) to 5.2 - DigestScheme overrideParamter not found

224 views Asked by At

I am working on migration of RestTemplate with digest Authentication from httpclient 4.x to 5.2. It was implemented using DigestScheme with overrideParamter - which is not longer available in 5.x Please find code below.

My code:

AuthCache authCache = new BasicAuthCache();
DigestScheme digestAuth = new DigestScheme();
//below line cause complications error because method not found
digestAuth.overrideParamter(“realm”,digestRealm);
authCache.put(host, digestAuth);

I tried to find example in the Internet but all tutorials are about 4.x version.

Maybe someone did it already and can help?

0

There are 0 answers