//+-------------------------------------------------------------------------
//
//  Microsoft Windows
//
//  Copyright (C) Microsoft Corporation, 1994 - 1999
//
//  File:       conv.idl
//
//--------------------------------------------------------------------------

[uuid(333a2276-0000-0000-0d00-00809c000000),version(3)]
interface conv
{

import "nbase.idl";

typedef unsigned long error_status_t;

[idempotent]
  void conv_who_are_you(
      [in]        handle_t     Binding,
      [in, ref]  UUID          *pUuid,
      [in]       unsigned long  ServerBootTime,
      [out, ref] unsigned long *SequenceNumber,
      [out, ref] error_status_t *Status
      );

[idempotent]
  void conv_who_are_you2(
      [in]        handle_t     Binding,
      [in, ref]  UUID          *pUuid,
      [in]       unsigned long  ServerBootTime,
      [out, ref] unsigned long *SequenceNumber,
      [out, ref] UUID          *CASUuid,
      [out, ref] error_status_t *Status
      );

[idempotent]
  void conv_are_you_there(
      [in]       handle_t         Binding,
      [in, ref]  UUID *           pUuid,
      [in]       unsigned long    ServerBootTime,
      [out, ref] error_status_t * Status
      );

[idempotent]
    void conv_who_are_you_auth(
        [in]        handle_t        Binding,
        [in, ref]  UUID         *   pUuid,
        [in]       unsigned long    ServerBootTime,
        [in, size_is(InLength)] byte InData[],
        [in]       long             InLength,
        [in]       long             OutMaxLength,
        [out, ref] unsigned long *  SequenceNumber,
        [out, ref] UUID          *  CASUuid,
        [out, length_is(*pOutLength), size_is(OutMaxLength)]
                   byte             OutData[],
        [out]      long *           pOutLength,
        [out, ref] error_status_t * Status
        );

/*
 * C O N V _ W H O _ A R E _ Y O U _ A U T H _ M O R E
 *
 * This routine is used, in conjunction with the conv_who_are_you_auth()
 * operation, for retrieving oversized PACs.  In the event that a client's
 * credentials are too large to fit within a single DG packet, the server
 * can retrieve the PAC, packet by packet, by repeated calls on this
 * operation.
 *
 * Note that because the "conv" interface is serviced directly by the
 * the DG protocol (as opposed to being handled by a call executor thread),
 * there is no additional client overhead with retrieving the PAC by
 * multiple single-packet calls, rather than a single multiple-packet call.
 * The small amount of overhead induced on the server side is more than
 * compensated for by being able to avoid adding flow-control/windowing
 * to the DG protocol's internal handling of the conv interface.
 *
 * Logically, this call returns
 *
 *        client_credentials[index ... (index+out_max_len-1)]
 */

[idempotent]
void conv_who_are_you_auth_more(
        [in]        handle_t        Binding,
        [in, ref]  UUID         *   pUuid,
        [in]       unsigned long    ServerBootTime,
        [in]       long             Index,
        [in]       long             OutMaxLength,
        [out, length_is(*pOutLength), size_is(OutMaxLength)]
                   byte             OutData[],
        [out]      long *           pOutLength,
        [out, ref] error_status_t * Status

        );
}