Python Web Apps that Fly with CDNs Transcripts
Chapter: Integrating Static Content
Lecture: Be careful with private content

Login or purchase this course to watch this video and the rest of the course contents.
0:00 Finally, let's end this chapter with a quick little bit of a warning. If we're caching stuff super hard and replicating it
0:08 and sharing it with people throughout the globe, you clearly don't want to take somebody's private content.
0:14 Like here's the listing of your account page with your email address and the last four of your credit cards, and then give that to someone else
0:22 when they tried to get to the account page and said, "Well, I got a cached version for you." Guess what? Here it is.
0:27 So my rule of thumb is just don't put private content through the CDN and be careful with that.
0:35 The way that bunny.net works is if you return a cookie as part of the response, it thinks that might be private and it'll never ever cache that.
0:44 I can't find that in writing and I don't see any documentation on how to deal with this. But when talking to the people there, that's what they said.
0:51 So I would just say don't, don't serve private content through this CDN. just not what it's for at the moment. There's stuff that they're working on
1:01 that might make this awesome and possible but at the time not yet. So just be aware of this, okay?


Talk Python's Mastodon Michael Kennedy's Mastodon