➕ add SameSite parameter as requested in issue #11.
0️⃣ By default, SameSite is undefined and unspecified in Set-Cookie. Acceptable values are securecookie.None, securecookie.Lax and securecookie.Strict. A SameSite parameter with value None is specified in Set-Cookie only when Secure is true.
➕ Add accessor method
Name()and complete example.
➕ Add function
MustGenerateRandomKey. This function calls
GenerateRandomKeyand panics if it returns an error. This function is intended to be used to initialize the key outside of any function like this:
🚀 This is the same release as v1.0 with the difference that the tag is now v1.0.0 so that it is recognized by go module tools.
The files go.mod and go.sum have been added.
✅ The dependency with
github.com/gorilla/securecookieis only because it is used for benchmarks with tests.
🚀 This release fixes the validity check of the cookie domain name field value.
Previously, the function would reject domain names with hyphens or uppercase letters.
Now the function will accept hyphens in domain names, uppercase letters and will ensure label length limits are respected, according to the specifications.
🔒 The fixed errors did not affect security. It only restricted accepted domain names and thus usability.
- 📦 Renamed the package as securecookie.
- ➕ Added travis CI, coverage test, and go report badges.
- Code coverage is 100%.
- 🛠 Fixed the few issues reported by go report. It's now rated A+.
- 📦 The package is still referenced as beta stage because it needs more feedback and experience.
🚀 This release removes all heap allocation in secure cookie value encoding and decoding methods.
📦 The package will be renamed into securecookie for clarity of its purpose.