-
-
Notifications
You must be signed in to change notification settings - Fork 747
Expand file tree
/
Copy pathCookie.cs
More file actions
59 lines (50 loc) · 2.08 KB
/
Cookie.cs
File metadata and controls
59 lines (50 loc) · 2.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
namespace ElectronNET.API.Entities
{
/// <summary>
/// Cookie structure as used by Electron session.cookies APIs.
/// </summary>
/// <remarks>Up-to-date with Electron API 39.2</remarks>
public class Cookie
{
/// <summary>
/// Gets or sets the name of the cookie.
/// </summary>
public string Name { get; set; }
/// <summary>
/// Gets or sets the value of the cookie.
/// </summary>
public string Value { get; set; }
/// <summary>
/// Gets or sets the domain of the cookie; this will be normalized with a preceding dot so that it's also valid for subdomains.
/// </summary>
public string Domain { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the cookie is a host-only cookie; this will only be true if no domain was passed.
/// </summary>
public bool? HostOnly { get; set; }
/// <summary>
/// Gets or sets the path of the cookie.
/// </summary>
public string Path { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the cookie is marked as secure.
/// </summary>
public bool? Secure { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the cookie is marked as HTTP only.
/// </summary>
public bool? HttpOnly { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the cookie is a session cookie or a persistent cookie with an expiration date.
/// </summary>
public bool? Session { get; set; }
/// <summary>
/// Gets or sets the expiration date of the cookie as the number of seconds since the UNIX epoch. Not provided for session cookies.
/// </summary>
public double? ExpirationDate { get; set; }
/// <summary>
/// Gets or sets the SameSite policy applied to this cookie. Can be "unspecified", "no_restriction", "lax" or "strict".
/// </summary>
public string SameSite { get; set; }
}
}