#pragma ident "%Z%%M% %I% %E% SMI"
/*
* The contents of this file are subject to the Netscape Public
* License Version 1.1 (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.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
* implied. See the License for the specific language governing
* rights and limitations under the License.
*
* The Original Code is Mozilla Communicator client code, released
* March 31, 1998.
*
* The Initial Developer of the Original Code is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998-1999 Netscape Communications Corporation. All
* Rights Reserved.
*
* Contributor(s):
*/
#include "ldap-int.h"
/* ldap_create_proxyauth_control
Create a "version 1" proxied authorization control.
Parameters are
ld LDAP pointer to the desired connection
dn The dn used in the proxy auth
ctl_iscritical Indicates whether the control is critical of not. If
this field is non-zero, the operation will only be car-
ried out if the control is recognized by the server
ctrlp the address of a place to put the constructed control
*/
int
const char *dn,
const char ctl_iscritical,
)
{
int rc;
if ( !NSLDAPI_VALID_LDAP_POINTER( ld )) {
return( LDAP_PARAM_ERROR );
}
return ( LDAP_PARAM_ERROR );
}
{
dn = "";
}
/* create a ber package to hold the controlValue */
return( LDAP_NO_MEMORY );
}
"{s}",
dn ) )
{
return( LDAP_ENCODING_ERROR );
}
ctl_iscritical, ctrlp );
return( rc );
}
/* ldap_create_proxiedauth_control
Create a "version 2" proxied authorization control.
Parameters are
ld LDAP pointer to the desired connection
authzid The authorization identity used in the proxy auth,
e.g., dn:uid=bjensen,dc=example,dc=com
ctrlp the address of a place to put the constructed control
*/
int
const char *authzid,
)
{
int rc;
if ( !NSLDAPI_VALID_LDAP_POINTER( ld )) {
return( LDAP_PARAM_ERROR );
}
return ( LDAP_PARAM_ERROR );
}
/* create a ber package to hold the controlValue */
return( LDAP_NO_MEMORY );
}
"s",
authzid ) )
{
return( LDAP_ENCODING_ERROR );
}
return( rc );
}