[ragel-users] Nested parsing
thurston at complang.org
Sun Feb 21 11:34:50 PST 2010
For base64 I would not recommend using getkey to decode. I think your
best bet is to write one decoder that writes into a buffer, that when
filled, is flushed to the email parser.
There is a permissively licensed base64 decoder here.
Note that this is a modified base64 that uses "-_" instead of "+/".
Eric Brown wrote:
> I'm trying to look for URLs embedded in email messages. However, the email messages themselves may be base64 or quoted-printable encoded. I could just decode the base64 or quoted-printable into one buffer and then search for URLs. Email messages can be large and I could do it in blocks of data intermittently resuming parsers, etc. I also thought of using the getkey statement and decoding the base64 or quoted-printable that way, but documentation says this could be called more than once per character. Is there any easier way to chain 2 parsers like this?
> ragel-users mailing list
> ragel-users at complang.org
More information about the ragel-users