Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tnef_attachement.name is not unicode #7

Closed
guettli opened this issue Nov 26, 2014 · 9 comments
Closed

tnef_attachement.name is not unicode #7

guettli opened this issue Nov 26, 2014 · 9 comments

Comments

@guettli
Copy link

guettli commented Nov 26, 2014

I get a UnicodeError in my application code, because tnef_attachement.name is not unicode.

Could the tnef library get updated, to make tnef_attachement.name a unicode string?

In my case it looks like a latin1 string. It would improve the usability of the library if the application programmer does not need to do string decoding.

Sorry, I can't post the tnef binary, since it is from a customer.

BTW, how can you create tnef test binaries?

@plq
Copy link

plq commented Apr 5, 2017

fixed in fbcecac if you call long_filename() AND there is a long filename to return

@guettli
Copy link
Author

guettli commented Apr 6, 2017

Unfortunately I don't have the matching test here to proof if the patch solves this issue.

I trust you and I think this issue can be closed.

Should I close it?

@plq
Copy link

plq commented Apr 7, 2017

I'm not in position to make that decision.

@petri
Copy link
Member

petri commented Nov 3, 2017

Please, if you can, provide a PR.

@petri
Copy link
Member

petri commented Mar 1, 2018

Note: master now strips null bytes from long_filename as well.

@petri
Copy link
Member

petri commented Mar 2, 2018

The encoding of tnef attachment (long) names is a bit tricky to get right, it's not exactly simple.

See for example the discussion at roundcube/roundcubemail#5646 .

If you have good understanding of how the encodings in tnef attachments work or any links to information, that would help.

@petri
Copy link
Member

petri commented Mar 2, 2018

Note: we should also consider how this is to work on Python2 vs. Python3 (with help of six?)

@jrideout
Copy link
Collaborator

This should be addressed by #31

@petri petri closed this as completed Nov 29, 2018
jrideout pushed a commit to agaridata/tnefparse that referenced this issue Nov 30, 2018
@guettli
Copy link
Author

guettli commented Dec 4, 2018

thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants