/*
*/
/*
* lib/krb5/os/changepw.c
*
* Copyright 1990,1999 by the Massachusetts Institute of Technology.
* All Rights Reserved.
*
* Export of this software from the United States of America may
* require a specific license from the United States Government.
* It is the responsibility of any person or organization contemplating
* export to obtain such a license before exporting.
*
* WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
* distribute this software and its documentation for any purpose and
* without fee is hereby granted, provided that the above copyright
* notice appear in all copies and that both that copyright notice and
* this permission notice appear in supporting documentation, and that
* the name of M.I.T. not be used in advertising or publicity pertaining
* to distribution of the software without specific, written prior
* permission. Furthermore if you modify this software you must label
* your software as modified software and not distribute it in such a
* fashion that it might be confused with the original M.I.T. software.
* M.I.T. makes no representations about the suitability of
* this software for any purpose. It is provided "as is" without express
* or implied warranty.
*
*/
#define NEED_SOCKETS
#include <k5-int.h>
#include <client_internal.h>
#include <gssapi_krb5.h>
#include <gssapiP_krb5.h>
#include <krb5.h>
/* #include "adm_err.h" */
#include <stdio.h>
#include <errno.h>
/*
* _kadm5_get_kpasswd_protocol
*
* returns the password change protocol value to the caller.
* Since the 'handle' is an opaque value to higher up callers,
* this method is needed to provide a way for them to get a peek
* at the protocol being used without having to expose the entire
* handle structure.
*/
{
}
/*
* kadm5_chpass_principal_v2
*
* New function used to prepare to make the change password request to a
* non-SEAM admin server. The protocol used in this case is not based on
* RPCSEC_GSS, it simply makes the request to port 464 (udp and tcp).
* This is the same way that MIT KRB5 1.2.1 changes passwords.
*/
char *newpw,
{
int cpwlen;
int tmp_rsp_code;
/*
* The credentials have already been stored in the cache in the
* initialization step earlier, but we dont have direct access to it
* at this level. Derive the cache and fetch the credentials to use for
* sending the request.
*/
&ccache)))
return (code);
/* set the client principal in the credential match structure */
/*
* match struct
*/
if (cpw_service == NULL) {
return (ENOMEM);
}
/* generate the server principal from the name string we generated */
return (code);
}
/* Find the credentials in the cache */
&ncreds))) {
return (code);
}
/* Now we have all we need to make the change request. */
return (result);
}