public inbox for gost@lists.cypherpunks.ru
Atom feed
* Паддинг ISO 10126
@ 2022-02-03 8:52 Евгений
2022-02-04 15:23 ` Sergey Matveev
0 siblings, 1 reply; 2+ messages in thread
From: Евгений @ 2022-02-03 8:52 UTC (permalink / raw)
To: gost
[-- Attachment #1: Type: text/plain, Size: 765 bytes --]
Добрый день.
Смотрю сейчас сервисы ФСС (https://eln.fss.ru/).
Они используют отозванный паддинг ISO 10126 (
https://en.wikipedia.org/wiki/Padding_(cryptography)#ISO_10126).
Интересно много ли людей его используют?
Нет ли смысла добавить его в pygost?
Реализация могла бы выглядеть как-то так:
def pad_iso10126(data, blocksize):
'''ISO 10126 (withdrawn)'''
padding = blocksize - len(data) % blocksize
if padding == 0: padding = blocksize
return data + urandom(padding - 1) + bytes([padding])
def unpad_iso10126(data):
'''ISO 10126 (withdrawn)'''
return data[:-data[-1]]
[-- Attachment #2: Type: text/html, Size: 1049 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-02-04 15:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-03 8:52 Паддинг ISO 10126 Евгений
2022-02-04 15:23 ` Sergey Matveev