Share via


DerivedKeyToken.Offset Property

Gets or sets the position at which the derived key is located in the byte stream for a serialized DerivedKeyToken.

Namespace: Microsoft.Web.Services3.Security.Tokens
Assembly: Microsoft.Web.Services3 (in microsoft.web.services3.dll)

Usage

'Usage
Dim derivedKeyToken1 As DerivedKeyToken

Dim returnValue As Integer
returnValue = derivedKeyToken1.Offset

Dim sampleValue As Integer
derivedKeyToken1.Offset = sampleValue

Syntax

'Declaration
Public Property Offset() As Integer
public int Offset {get; set;}
public:
property int Offset {
    int get();
    void set(int value);
}
public int get_Offset();
public void set_Offset(int);
public function get Offset() : int;
public function set Offset(int);

Property Value

The position at which the derived key is located in the byte stream for a serialized DerivedKeyToken, expressed in bytes.

Exceptions

Exception type Condition
ArgumentOutOfRangeException

Offset is set to value less than zero.

Remarks

The Generation and Offset properties determine the location at which the derived key is placed in the byte stream for a serialized DerivedKeyToken in a WS-Security SOAP header. If the Offset property is greater than zero, then the derived key is offset from the beginning of the byte stream by the value of the Offset property, in bytes; otherwise the derived key is offset by the value of the Generation property multiplied by the value of the Length property.

Set either the Generation or the Offset property, but not both. Setting the value of either the Generation or the Offset property disables the other from being used to determine the derived key position in the generated byte stream. A value of -1 indicates the property is disabled from determining the location at which derived key is placed.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Development Platforms

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, Windows 2000, Windows 2000 Server, Windows 2000 Advanced Server

Target Platforms

See Also

Reference

DerivedKeyToken Class
DerivedKeyToken Members
Microsoft.Web.Services3.Security.Tokens Namespace
Generation