Binding Problem on VC++ 6.0 with SP5

G

Guest

Guest
Archived from groups: microsoft.public.win2000.active_directory (More info?)

1.Binding Problem on VC++ 6.0 with SP5:

When i use (ldap_bind_s ) or (ldap_simple_bind_s ) for binding with active
directory with Another user Credentials (Another user is a SYSTEM Account
),it won't work and give me "SERVER DOWN ".The development enviroment is
visual c++6.0 with SP5.

2.Binding Problem on DOTNET
When i use (ldap_bind_s ) or (ldap_simple_bind_s ) for binding with active
directory with Another user Credentials (Another user is a SYSTEM Account )
it bind the user with active directory and perform all the operation on
directory successfully.this time development envi

Note:
i cannot understand that by just changing the development environment from
DOTNET to VC++6.0 (ldap_bind_s )won't work
 
G

Guest

Guest
Archived from groups: microsoft.public.win2000.active_directory (More info?)

You should give more info here. What do you mean by it is a "SYSTEM Account"?

You should also give the actual code sequence.

joe

--
Joe Richards Microsoft MVP Windows Server Directory Services
www.joeware.net


Muhammad Ali khan wrote:
> 1.Binding Problem on VC++ 6.0 with SP5:
>
> When i use (ldap_bind_s ) or (ldap_simple_bind_s ) for binding with active
> directory with Another user Credentials (Another user is a SYSTEM Account
> ),it won't work and give me "SERVER DOWN ".The development enviroment is
> visual c++6.0 with SP5.
>
> 2.Binding Problem on DOTNET
> When i use (ldap_bind_s ) or (ldap_simple_bind_s ) for binding with active
> directory with Another user Credentials (Another user is a SYSTEM Account )
> it bind the user with active directory and perform all the operation on
> directory successfully.this time development envi
>
> Note:
> i cannot understand that by just changing the development environment from
> DOTNET to VC++6.0 (ldap_bind_s )won't work
 
G

Guest

Guest
Archived from groups: microsoft.public.win2000.active_directory (More info?)

While your Question What do you mean by it is a "SYSTEM Account"?.
Anwser : "malikhan" is a login name of account having Administrative,Schema
Admin Previledges.By specifying "SYSTEM Account" i just want to specify that
account have Administrative,Schema Admin Previledges and nothing more.
Actual code sequece is given below.

The Sample Code is given Below
The parameters used in code has folowing values
HostName = "test"
portNo = 389
AuthString = "malikhan" // user loginname
AuthString = "test.com" // Domain Name
WinPass= "secret" // user loginname

Actual Code is Given Below :

psLdap = ldap_init( HostName, PortNo);

if( psLdap != NULL )
{

const PCHAR pszUserName = (const PCHAR)AuthString;
const PCHAR pszDomainName=(const PCHAR)DomainDotCom ;
const PCHAR pszPassword = (const PCHAR)WinPass;

SEC_WINNT_AUTH_IDENTITY sIdentity;

sIdentity.User = ( unsigned char* )pszUserName;
sIdentity.UserLength = strlen( pszUserName );
sIdentity.Domain = ( unsigned char* )pszDomainName;
sIdentity.DomainLength = strlen( pszDomainName );
sIdentity.Password = ( unsigned char* )pszPassword;
sIdentity.PasswordLength = strlen( pszPassword );
sIdentity.Flags = SEC_WINNT_AUTH_IDENTITY_ANSI;

uErr = ldap_bind_s(
psLdap,
pszUserName,
( const PCHAR )&sIdentity,
LDAP_AUTH_NEGOTIATE
);
}

"Joe Richards [MVP]" wrote:

> You should give more info here. What do you mean by it is a "SYSTEM Account"?
>
> You should also give the actual code sequence.
>
> joe
>
> --
> Joe Richards Microsoft MVP Windows Server Directory Services
> www.joeware.net
>
>
> Muhammad Ali khan wrote:
> > 1.Binding Problem on VC++ 6.0 with SP5:
> >
> > When i use (ldap_bind_s ) or (ldap_simple_bind_s ) for binding with active
> > directory with Another user Credentials (Another user is a SYSTEM Account
> > ),it won't work and give me "SERVER DOWN ".The development enviroment is
> > visual c++6.0 with SP5.
> >
> > 2.Binding Problem on DOTNET
> > When i use (ldap_bind_s ) or (ldap_simple_bind_s ) for binding with active
> > directory with Another user Credentials (Another user is a SYSTEM Account )
> > it bind the user with active directory and perform all the operation on
> > directory successfully.this time development envi
> >
> > Note:
> > i cannot understand that by just changing the development environment from
> > DOTNET to VC++6.0 (ldap_bind_s )won't work
>