FreeRDP
per.h File Reference
#include <freerdp/api.h>
#include <winpr/stream.h>
This graph shows which files directly or indirectly include this file:

Functions

FREERDP_API BOOL per_read_length (wStream *s, UINT16 *length)
 
FREERDP_API BOOL per_write_length (wStream *s, UINT16 length)
 
FREERDP_API BOOL per_read_choice (wStream *s, BYTE *choice)
 
FREERDP_API BOOL per_write_choice (wStream *s, BYTE choice)
 
FREERDP_API BOOL per_read_selection (wStream *s, BYTE *selection)
 
FREERDP_API BOOL per_write_selection (wStream *s, BYTE selection)
 
FREERDP_API BOOL per_read_number_of_sets (wStream *s, BYTE *number)
 
FREERDP_API BOOL per_write_number_of_sets (wStream *s, BYTE number)
 
FREERDP_API BOOL per_read_padding (wStream *s, UINT16 length)
 
FREERDP_API BOOL per_write_padding (wStream *s, UINT16 length)
 
FREERDP_API BOOL per_read_integer (wStream *s, UINT32 *integer)
 
FREERDP_API BOOL per_read_integer16 (wStream *s, UINT16 *integer, UINT16 min)
 
FREERDP_API BOOL per_write_integer (wStream *s, UINT32 integer)
 
FREERDP_API BOOL per_write_integer16 (wStream *s, UINT16 integer, UINT16 min)
 
FREERDP_API BOOL per_read_enumerated (wStream *s, BYTE *enumerated, BYTE count)
 
FREERDP_API BOOL per_write_enumerated (wStream *s, BYTE enumerated, BYTE count)
 
FREERDP_API BOOL per_write_object_identifier (wStream *s, const BYTE oid[6])
 
FREERDP_API BOOL per_read_object_identifier (wStream *s, const BYTE oid[6])
 
FREERDP_API BOOL per_read_octet_string (wStream *s, const BYTE *oct_str, UINT16 length, UINT16 min)
 
FREERDP_API BOOL per_write_octet_string (wStream *s, const BYTE *oct_str, UINT16 length, UINT16 min)
 
FREERDP_API BOOL per_read_numeric_string (wStream *s, UINT16 min)
 
FREERDP_API BOOL per_write_numeric_string (wStream *s, const BYTE *num_str, UINT16 length, UINT16 min)
 

Function Documentation

◆ per_read_choice()

FREERDP_API BOOL per_read_choice ( wStream s,
BYTE choice 
)

Read PER choice.

Parameters
sstream
choicechoice
Returns
TRUE for success, FALSE otherwise.
Here is the caller graph for this function:

◆ per_read_enumerated()

FREERDP_API BOOL per_read_enumerated ( wStream s,
BYTE enumerated,
BYTE  count 
)

Read PER ENUMERATED.

Parameters
sThe stream to read from
enumeratedenumerated result variable, must not be NULL
countenumeration count
Returns
TRUE for success, FALSE otherwise
Here is the caller graph for this function:

◆ per_read_integer()

FREERDP_API BOOL per_read_integer ( wStream s,
UINT32 *  integer 
)

Read PER INTEGER.

Parameters
sstream
integerinteger
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_read_integer16()

FREERDP_API BOOL per_read_integer16 ( wStream s,
UINT16 integer,
UINT16  min 
)

Read PER INTEGER (UINT16).

Parameters
sThe stream to read from
integerThe integer result variable pointer, must not be NULL
minminimum value
Returns
TRUE for success, FALSE otherwise
Here is the caller graph for this function:

◆ per_read_length()

FREERDP_API BOOL per_read_length ( wStream s,
UINT16 length 
)

FreeRDP: A Remote Desktop Protocol Implementation ASN.1 Packed Encoding Rules (BER)

Copyright 2011-2012 Marc-Andre Moreau marca.nosp@m.ndre.nosp@m..more.nosp@m.au@g.nosp@m.mail..nosp@m.com

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Read PER length.

Parameters
sstream to read from
lengthA pointer to return the length read, must not be NULL
Returns
TRUE for success, FALSE otherwise.
Here is the caller graph for this function:

◆ per_read_number_of_sets()

FREERDP_API BOOL per_read_number_of_sets ( wStream s,
BYTE number 
)

Read PER number of sets.

Parameters
sstream
numbernumber of sets
Returns
TRUE for success, FALSE otherwise.
Here is the caller graph for this function:

◆ per_read_numeric_string()

FREERDP_API BOOL per_read_numeric_string ( wStream s,
UINT16  min 
)

Read PER NumericString.

Parameters
sstream
minminimum string length
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_read_object_identifier()

FREERDP_API BOOL per_read_object_identifier ( wStream s,
const BYTE  oid[6] 
)

Read PER OBJECT_IDENTIFIER (OID).

Parameters
sThe stream to read from
oidobject identifier (OID)
Warning
It works correctly only for limited set of OIDs.
Returns
TRUE for success, FALSE otherwise
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_read_octet_string()

FREERDP_API BOOL per_read_octet_string ( wStream s,
const BYTE oct_str,
UINT16  length,
UINT16  min 
)

Read PER OCTET_STRING.

Parameters
sThe stream to read from
oct_stroctet string
lengthstring length
minminimum length
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_read_padding()

FREERDP_API BOOL per_read_padding ( wStream s,
UINT16  length 
)

Read PER padding with zeros.

Parameters
sA stream to read from
lengththe data to write
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_read_selection()

FREERDP_API BOOL per_read_selection ( wStream s,
BYTE selection 
)

Read PER selection.

Parameters
sstream
selectionselection
Returns
TRUE for success, FALSE otherwise.
Here is the caller graph for this function:

◆ per_write_choice()

FREERDP_API BOOL per_write_choice ( wStream s,
BYTE  choice 
)

Write PER CHOICE.

Parameters
sstream
choiceindex of chosen field
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_enumerated()

FREERDP_API BOOL per_write_enumerated ( wStream s,
BYTE  enumerated,
BYTE  count 
)

Write PER ENUMERATED.

Parameters
sThe stream to write to
enumeratedenumerated
countenumeration count
Returns
TRUE for success, FALSE otherwise
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_integer()

FREERDP_API BOOL per_write_integer ( wStream s,
UINT32  integer 
)

Write PER INTEGER.

Parameters
sstream
integerinteger
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_integer16()

FREERDP_API BOOL per_write_integer16 ( wStream s,
UINT16  integer,
UINT16  min 
)

Write PER INTEGER (UINT16).

Parameters
sstream
integerinteger
minminimum value
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_length()

FREERDP_API BOOL per_write_length ( wStream s,
UINT16  length 
)

Write PER length.

Parameters
sstream
lengthlength
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_number_of_sets()

FREERDP_API BOOL per_write_number_of_sets ( wStream s,
BYTE  number 
)

Write PER number of sets for SET OF.

Parameters
sstream
numbernumber of sets
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_numeric_string()

FREERDP_API BOOL per_write_numeric_string ( wStream s,
const BYTE num_str,
UINT16  length,
UINT16  min 
)

Write PER NumericString.

Parameters
sstream
num_strnumeric string
lengthstring length
minminimum string length
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_object_identifier()

FREERDP_API BOOL per_write_object_identifier ( wStream s,
const BYTE  oid[6] 
)

Write PER OBJECT_IDENTIFIER (OID)

Parameters
sstream
oidobject identifier (oid)
Warning
It works correctly only for limited set of OIDs.
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_octet_string()

FREERDP_API BOOL per_write_octet_string ( wStream s,
const BYTE oct_str,
UINT16  length,
UINT16  min 
)

Write PER OCTET_STRING

Parameters
sstream
oct_stroctet string
lengthstring length
minminimum string length
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_padding()

FREERDP_API BOOL per_write_padding ( wStream s,
UINT16  length 
)

Write PER padding with zeros.

Parameters
sA stream to write to
lengththe data to write
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ per_write_selection()

FREERDP_API BOOL per_write_selection ( wStream s,
BYTE  selection 
)

Write PER selection for OPTIONAL fields.

Parameters
sstream
selectionbit map of selected fields
Returns
TRUE for success, FALSE otherwise.
Here is the call graph for this function:
Here is the caller graph for this function: