Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
kstenerud
on Oct 10, 2019
|
parent
|
context
|
favorite
| on:
UTF-8 history (2003)
You can do the same thing using VLQ, with less wastage. Just scan for the next cleared high bit.
mirekrusin
on Oct 10, 2019
[–]
You can also construct malicious payloads which will DoS many implementations with architecture like that.
kstenerud
on Oct 10, 2019
|
parent
[–]
You can also trivially defend against that by having a max travel distance of, say, 4.
mirekrusin
on Oct 13, 2019
|
root
|
parent
|
next
[–]
Exactly, so you arrived at the same conclusion - fixed distance so you can safely pick up stream at arbitrary position.
kstenerud
on Oct 13, 2019
|
root
|
parent
|
next
[–]
The difference is that the distance limits would be inherent to the codec itself, rather than taking up extra space in the data stream.
ludamad
on Oct 10, 2019
|
root
|
parent
|
prev
[–]
Is that guaranteed to catch all valid cases?
Consider applying for YC's Summer 2025 batch! Applications are open till May 13
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: