Skip to content

Commit ea85f15

Browse files
docs: Mention that PEM format includes the begin/end markers (#2491)
1 parent 4ebfb5f commit ea85f15

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

com.unity.netcode.gameobjects/Runtime/Transports/UTP/UnityTransport.cs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1432,6 +1432,10 @@ private void ConfigureSimulatorForUtp1()
14321432
private string m_ClientCaCertificate;
14331433

14341434
/// <summary>Set the server parameters for encryption.</summary>
1435+
/// <remarks>
1436+
/// The public certificate and private key are expected to be in the PEM format, including
1437+
/// the begin/end markers like <c>-----BEGIN CERTIFICATE-----</c>.
1438+
/// </remarks>
14351439
/// <param name="serverCertificate">Public certificate for the server (PEM format).</param>
14361440
/// <param name="serverPrivateKey">Private key for the server (PEM format).</param>
14371441
public void SetServerSecrets(string serverCertificate, string serverPrivateKey)
@@ -1442,9 +1446,15 @@ public void SetServerSecrets(string serverCertificate, string serverPrivateKey)
14421446

14431447
/// <summary>Set the client parameters for encryption.</summary>
14441448
/// <remarks>
1449+
/// <para>
14451450
/// If the CA certificate is not provided, validation will be done against the OS/browser
14461451
/// certificate store. This is what you'd want if using certificates from a known provider.
14471452
/// For self-signed certificates, the CA certificate needs to be provided.
1453+
/// </para>
1454+
/// <para>
1455+
/// The CA certificate (if provided) is expected to be in the PEM format, including the
1456+
/// begin/end markers like <c>-----BEGIN CERTIFICATE-----</c>.
1457+
/// </para>
14481458
/// </remarks>
14491459
/// <param name="serverCommonName">Common name of the server (typically hostname).</param>
14501460
/// <param name="caCertificate">CA certificate used to validate the server's authenticity.</param>

0 commit comments

Comments
 (0)