SessionSecurityTokenHandler.ApplyTransforms(Byte[], Boolean) Method

Definition

Applies the transforms specified by the Transforms property to either encode or decode the specified cookie.

protected virtual byte[] ApplyTransforms(byte[] cookie, bool outbound);

Parameters

cookie
Byte[]

The cookie that will be transformed.

outbound
Boolean

true if the cookie should be encoded; false if the cookie should be decoded.

Returns

Byte[]

The encoded or decoded cookie.

Exceptions

The Transforms property is null.

Remarks

When encoding a cookie transforms are applied in the order in which they appear in the Transforms property. When decoding a cookie, they are applied in the reverse order.

Called from the WriteToken and ReadToken methods to encode and decode the cookie material.

Applies to

Product Versions
.NET Framework 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1