Open phyber opened 6 months ago
Hi,
Yes. I think you are correct. I have been thinking this needed to be changed. Take a look at the dev branch if you want to submit a pull request.
Note that there are big changes coming.
I am in the process of moving through current SPF Struct to SpfBuilder and a leaner simpler Spf Struct is being added.
Will have support to iterate over the mechanism types. As well as covert Spf into a Spfbuilder.
Current away. So I will look at the change in a day or two.
Also if you could leave the sample sod record. I will add it as a test case.
@phyber I have pushed a possible v0.2.7 version to github. Please test with this code and let me know how it goes.
https://github.com/Bas-Man/rust-decon-spf/tree/v0.2.7.candidate
You might be right. Might be worth relaxing the rule. I will see if I can do something along these lines with version 0.3.0.
Hi,
I'm attempting to parse an SPF record that is longer than 255 characters which results which in a
SourceLengthExceeded
error.I'm not sure this error should be triggered here. RFC 7208 section 3.3 says:
I'm guessing that the TXT record length limit is where the 255 number comes from, but section 3.4 says:
It feels like the string length here should be increased to at least 512 characters, even then, it's only a
SHOULD
and some DNS implementations could be returning more characters.Does a length check need to exist here at all? Perhaps a warning about the potential record lengths in the documentation is enough, with links to what the RFC has to say on the matter.