开发者

Best data length for storing OAuth tokens

I want to write a mysql database schema for storing OAuth access tokens which is sufficiently generic so that it is capable for supporting any provider that complies with the OAuth standard.

What would be a sensible data length to achieve this aim and why? As far as I can see, no maximum length is enforced by the standard and开发者_如何学Go I don't want to have to change my column length whenever I decide to support a new provider that happens to use larger tokens.

If this is not practical/possible, what would be a sensible length for supporting the more popular OAuth providers and why?

CHOSEN SOLUTION

Using a data type with an undefined length seems to be the only sufficiently generic option for my case.


You can use text data type for this if you don't know the exact length.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜