There’s a ton of great open-source libraries. iOS Cookies is a place, where you can browse them easily.