Quantcast
Channel: Claims based access platform (CBA), code-named Geneva forum
Viewing all articles
Browse latest Browse all 2535

replacing username token handlers

$
0
0

in

  

privatestaticvoidOnServiceConfigurationCreated(objectsender,ServiceConfigurationCreatedEventArgse)

let say I want to replace the windows specific usernamepassword handler.           

varunHandler =newCustomUserNameSecurityTokenHandler();

e.ServiceConfiguration.SecurityTokenHandlers.AddOrReplace(unHandler);

Is the use of AddOrReplace sufficient (to remove the windows handler)?

Or do I need to go find the windows handler and remove it explicitly?

var

x = e.ServiceConfiguration.SecurityTokenHandlers.Where<SecurityTokenHandler>(th => th.GetTokenTypeIdentifiers().Contains("foo"));

is there a better way to reference a particular registered handler?

I seem to recall seeing that line of code insome sample (a million lines of code ago).


Viewing all articles
Browse latest Browse all 2535

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>