Skip to content

Commit

Permalink
Adds SecurityDetails.subjectAlternativeNames (#2820)
Browse files Browse the repository at this point in the history
* Adds SecurityDetails.subjectAlternativeNames

which is part of the Puppeteer API but not yet in PuppeterSharp

* Patch version bump

---------

Co-authored-by: Jeff Peirson <Jeff.Peirson@a2ius.com>
  • Loading branch information
jpeirson and Jeff Peirson authored Nov 7, 2024
1 parent 874c78d commit c908c5c
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/PuppeteerSharp/PuppeteerSharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
<Description>Headless Browser .NET API</Description>
<PackageId>PuppeteerSharp</PackageId>
<PackageReleaseNotes></PackageReleaseNotes>
<PackageVersion>20.0.4</PackageVersion>
<ReleaseVersion>20.0.4</ReleaseVersion>
<AssemblyVersion>20.0.4</AssemblyVersion>
<FileVersion>20.0.4</FileVersion>
<PackageVersion>20.0.5</PackageVersion>
<ReleaseVersion>20.0.5</ReleaseVersion>
<AssemblyVersion>20.0.5</AssemblyVersion>
<FileVersion>20.0.5</FileVersion>
<SynchReleaseVersion>false</SynchReleaseVersion>
<StyleCopTreatErrorsAsWarnings>false</StyleCopTreatErrorsAsWarnings>
<DebugType>embedded</DebugType>
Expand Down
21 changes: 21 additions & 0 deletions lib/PuppeteerSharp/SecurityDetails.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,27 @@ public SecurityDetails()
/// <param name="validTo">Valid to.</param>
/// <param name="protocol">Protocol.</param>
public SecurityDetails(string subjectName, string issuer, long validFrom, long validTo, string protocol)
: this(subjectName, issuer, validFrom, validTo, protocol, [])
{
}

/// <summary>
/// Initializes a new instance of the <see cref="SecurityDetails"/> class.
/// </summary>
/// <param name="subjectName">Subject name.</param>
/// <param name="issuer">Issuer.</param>
/// <param name="validFrom">Valid from.</param>
/// <param name="validTo">Valid to.</param>
/// <param name="protocol">Protocol.</param>
/// <param name="subjectAlternativeNames">Subject alternative names.</param>
public SecurityDetails(string subjectName, string issuer, long validFrom, long validTo, string protocol, string[] subjectAlternativeNames)
{
SubjectName = subjectName;
Issuer = issuer;
ValidFrom = validFrom;
ValidTo = validTo;
Protocol = protocol;
SubjectAlternativeNames = subjectAlternativeNames;
}

/// <summary>
Expand Down Expand Up @@ -59,5 +74,11 @@ public SecurityDetails(string subjectName, string issuer, long validFrom, long v
/// </summary>
/// <value>The protocol.</value>
public string Protocol { get; set; }

/// <summary>
/// Gets the list of subject alternative names (SANs) of the certificate.
/// </summary>
/// <value>The list of subject alternative names (SANs) of the certificate.</value>
public string[] SubjectAlternativeNames { get; set; }
}
}

0 comments on commit c908c5c

Please sign in to comment.