[doc][security] use generic token factory in doc examples.
[doc][security] use generic token factory in doc examples.