!ATpnjyZppDvtXkQZYR:gitter.im

CherryPy

183 Members
CherryPy is a pythonic, object-oriented HTTP framework | file your bugs at: https://github.com/cherrypy/cherrypy/issues | FAQ: https://stackoverflow.com/questions/tagged/cheroot+or+cherrypy / https://github.com/cherrypy/cherrypy/discussions4 Servers

Load older messages


SenderMessageTime
29 Nov 2023
@lolilol93:matrix.org@lolilol93:matrix.org left the room.13:55:07
24 Dec 2023
@valetnoir:gitter.imvalet noir joined the room.21:03:38
9 Jan 2024
@radez:matrix.orgradez joined the room.18:44:26
@radez:matrix.orgradez @webknjaz πŸ‡ΊπŸ‡¦ #StandWithUkraine | https://stand-with-ukraine.pp.ua | #russiaIsANaziState: ping 18:46:53
@webknjaz:matrix.org@webknjaz
In reply to @radez:matrix.org
@webknjaz πŸ‡ΊπŸ‡¦ #StandWithUkraine | https://stand-with-ukraine.pp.ua | #russiaIsANaziState: ping
Hey πŸ‘‹
18:48:05
@radez:matrix.orgradezI was poking at https://github.com/cherrypy/cherrypy/issues/2014 looks like the cgi.parse_header is a 'Parse a Content-type like header'18:48:07
@radez:matrix.orgradezbut email module is a strict Content-Type header parser so it expects a / in the value18:48:35
@radez:matrix.orgradezthe email module is falling back to text/plain for everything because there is not a / in the value18:49:03
@radez:matrix.orgradezOh, and hello :)18:49:40
@radez:matrix.orgradez set a profile picture.18:50:31
@radez:matrix.orgradezso when cherrypy passes Accept-Encoding and Accept-Charset headers to that email headerparser they arn't being parsed properly.18:51:56
@radez:matrix.orgradezI haven't dug deeper into the workflow that gets to the emailmodule, curious if you have any thoughts before I dive in deeper18:52:35
@webknjaz:matrix.org@webknjazNot at the moment. Haven't looked into that in a while and probably reverted because there was no quick fix.19:01:37
@radez:matrix.orgradezOne option: the parse function that uses cgi.parse_header is for the httputil.HeaderElement object, which both seem generic. The code for the cgi.parse_header function was only a dozen lines. what if we copied the function from the deprecated module and replaced HeaderElement.parse with the cgi.parse_header code? parse_header is more suited to what the HeaderElement needs than what the EmailMessage does?19:06:00
@radez:matrix.orgradezI'm also happy to spend more time to see if I can figure out how to make EmailMessage work properly19:06:28
@webknjaz:matrix.org@webknjazI don't remember that code. Will need to have a look once I'm done with my dinner. But in general, feel free to document your findings in the issue so it's more transparent and searchable.19:36:36
@webknjaz:matrix.org@webknjaz

I guess vendoring that function is okay. Though, PEP 594 suggests what I did in my first attempt so I'd stick with that. Other projects do the same, from my googling.

What's exactly incompatible there?

22:12:03
@webknjaz:matrix.org@webknjazDo you have a specific traceback to share?22:13:45
@radez:matrix.orgradezI added a comment to the github issue with details on my findings. Let me know if it needs more clarification or discussion.23:59:29
10 Jan 2024
@dddh_gitlab:gitter.imDaniel Volchixin joined the room.00:23:56
@webknjaz:matrix.org@webknjazYes, I replied there. TL;DR add tests, then vendor.01:54:34
@radez:matrix.orgradezsounds like a plan. I'll work on it over the next couple weeks.04:10:05
22 Jan 2024
@rickselden:gitter.imrickselden joined the room.14:25:43
@rickselden:gitter.imrickseldenhi guys. I'm trying to get mTLS working with cherrypy 18.9 / Python 3.12. Is it possible to get cherrypy to check my client certs?14:26:58
@rickselden:gitter.imrickselden(the server is validating itself fine to the clients over https, that side is all working fine)14:29:36
@webknjaz:matrix.org@webknjaz You could try using cherrypy.config.update() to provide a replacement SSLContext object having your own initialization, I suppose. 15:49:57
23 Jan 2024
@rickselden:gitter.imrickseldenI tried that yesterday under ChatGPT4's guidance. Before I posted on here it got me all setup for server auth and generating my certs, but appeared to lack the precise knowledge about the SSLContext - which figures, not so much training data out there about this topic. Really glad to see the Ukraine message there boss. I watch Denys Davydov/YT every day intently for updates on the evil Russian terrorist situation. It's important to keep the message alive. I live in the UK where we all think Putin is an evil bastard. I will try revisiting the SSLContext. Thanks for the recommendation.06:20:42
@rickselden:gitter.imrickseldenone more question... has anyone you are aware of done what I'm trying to do on recent CherryPy without hacks/patches and just using the default libs? I find posts online discussing cherrypy client auth but they date back from 2017 and earlier talking about all sorts of hacky witchcraft that can crash the server, none of which sit right with me!?! cheers.06:33:26
@webknjaz:matrix.org@webknjaz
In reply to @rickselden:gitter.im
one more question... has anyone you are aware of done what I'm trying to do on recent CherryPy without hacks/patches and just using the default libs? I find posts online discussing cherrypy client auth but they date back from 2017 and earlier talking about all sorts of hacky witchcraft that can crash the server, none of which sit right with me!?! cheers.

There's a few bugs in Cheroot that are still unfixed. Cheroot used to be a part of CherryPy that is now separate and can be used standalone. It implements an HTTP server with the WSGI interface, essentially, while CherryPy is more of a web framework layer.

The builtin TLS module (the one from the CPython stdlib β€” ssl) seems to be more stable, while pyOpenSSL has bugs that may need fixes in that library and maybe on the Cheroot side too.

I keep wanting to find time to fix some of the Cheroot-side bugs. And there's contributors who're trying to look into the pyOpenSSL adapter, but that one is rather complicated.

On the CherryPy side, there's a few tiny incompatibilities with Python 3.13 that are being worked on by another contributor.

12:06:12
@webknjaz:matrix.org@webknjazThanks for your support!12:19:35

Show newer messages


Back to Room ListRoom Version: 6