summaryrefslogtreecommitdiff
path: root/source3/libsmb/clirap.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2002-07-15 10:35:28 +0000
committerAndrew Tridgell <tridge@samba.org>2002-07-15 10:35:28 +0000
commite90b65284812aaa5ff9e9935ce9bbad7791cbbcd (patch)
tree9e744d1dc2f93934a4b49166a37383d3cb2b2139 /source3/libsmb/clirap.c
parentec167dc9cc0ec2ee461837c25a371d2981744208 (diff)
downloadsamba-e90b65284812aaa5ff9e9935ce9bbad7791cbbcd.tar.gz
samba-e90b65284812aaa5ff9e9935ce9bbad7791cbbcd.tar.bz2
samba-e90b65284812aaa5ff9e9935ce9bbad7791cbbcd.zip
updated the 3.0 branch from the head branch - ready for alpha18
(This used to be commit 03ac082dcb375b6f3ca3d810a6a6367542bc23ce)
Diffstat (limited to 'source3/libsmb/clirap.c')
-rw-r--r--source3/libsmb/clirap.c14
1 files changed, 4 insertions, 10 deletions
diff --git a/source3/libsmb/clirap.c b/source3/libsmb/clirap.c
index a2b6c8bb8b..2064e14954 100644
--- a/source3/libsmb/clirap.c
+++ b/source3/libsmb/clirap.c
@@ -117,7 +117,8 @@ BOOL cli_NetWkstaUserLogon(struct cli_state *cli,char *user, char *workstation)
if (cli->rap_error == 0) {
DEBUG(4,("NetWkstaUserLogon success\n"));
cli->privileges = SVAL(p, 24);
- fstrcpy(cli->eff_name,p+2);
+ /* The cli->eff_name field used to be set here
+ but it wasn't used anywhere else. */
} else {
DEBUG(1,("NetwkstaUserLogon gave error %d\n", cli->rap_error));
}
@@ -283,8 +284,6 @@ BOOL cli_oem_change_password(struct cli_state *cli, const char *user, const char
char param[16+sizeof(fstring)];
char data[532];
char *p = param;
- fstring upper_case_old_pw;
- fstring upper_case_new_pw;
unsigned char old_pw_hash[16];
unsigned char new_pw_hash[16];
int data_len;
@@ -316,9 +315,7 @@ BOOL cli_oem_change_password(struct cli_state *cli, const char *user, const char
* Get the Lanman hash of the old password, we
* use this as the key to make_oem_passwd_hash().
*/
- memset(upper_case_old_pw, '\0', sizeof(upper_case_old_pw));
- clistr_push(cli, upper_case_old_pw, old_password, -1,STR_TERMINATE|STR_UPPER|STR_ASCII);
- E_P16((uchar *)upper_case_old_pw, old_pw_hash);
+ E_deshash(old_password, old_pw_hash);
clistr_push(cli, dos_new_password, new_password, -1, STR_TERMINATE|STR_ASCII);
@@ -328,10 +325,7 @@ BOOL cli_oem_change_password(struct cli_state *cli, const char *user, const char
/*
* Now place the old password hash in the data.
*/
- memset(upper_case_new_pw, '\0', sizeof(upper_case_new_pw));
- clistr_push(cli, upper_case_new_pw, new_password, -1, STR_TERMINATE|STR_UPPER|STR_ASCII);
-
- E_P16((uchar *)upper_case_new_pw, new_pw_hash);
+ E_deshash(new_password, new_pw_hash);
E_old_pw_hash( new_pw_hash, old_pw_hash, (uchar *)&data[516]);