| От | Bruno Wolff III |
|---|---|
| Тема | Re: Generating unique session ids |
| Дата | |
| Msg-id | 20060727201302.GA5478@wolff.to обсуждение исходный текст |
| Ответ на | Re: Generating unique session ids (Tomasz Ostrowski <tometzky@batory.org.pl>) |
| Список | pgsql-general |
On Thu, Jul 27, 2006 at 15:15:32 +0200, Tomasz Ostrowski <tometzky@batory.org.pl> wrote: > > * PostgreSQL integers (as returned by nextval()) are 4 bytes. This > means only 32 bit strength - much too low for today computers. They are actually 8 bytes. Since session ids aren't valuable for very long you could actually make a usable system out of this if you rekeyed frequently. If the issue is how to cheaply prevent collisions that might occur from using random session ids, one might consider concatenating a random string with a sequence. As long as the sequence won't wrap around before a session id will expire, this will prevent collisions.
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера