bpo-35647: Fix path check in cookiejar (GH-11436)


* Refactor cookie path check as per RFC 6265

* Add tests for prefix match of path

* Add news entry

* Fix set_ok_path and refactor tests

* Use slice for last letter
(cherry picked from commit 0e1f1f01058bd4a9b98cfe443214adecc019a38c)

Co-authored-by: Xtreak <tir.karthi@gmail.com>
3 files changed