Lines Matching refs:bcc_ptr

83 	char *bcc_ptr = *pbcc_area;  in unicode_oslm_strings()  local
87 bytes_ret = cifs_strtoUTF16((__le16 *)bcc_ptr, "Linux version ", 32, in unicode_oslm_strings()
89 bcc_ptr += 2 * bytes_ret; in unicode_oslm_strings()
90 bytes_ret = cifs_strtoUTF16((__le16 *) bcc_ptr, init_utsname()->release, in unicode_oslm_strings()
92 bcc_ptr += 2 * bytes_ret; in unicode_oslm_strings()
93 bcc_ptr += 2; /* trailing null */ in unicode_oslm_strings()
95 bytes_ret = cifs_strtoUTF16((__le16 *) bcc_ptr, CIFS_NETWORK_OPSYS, in unicode_oslm_strings()
97 bcc_ptr += 2 * bytes_ret; in unicode_oslm_strings()
98 bcc_ptr += 2; /* trailing null */ in unicode_oslm_strings()
100 *pbcc_area = bcc_ptr; in unicode_oslm_strings()
106 char *bcc_ptr = *pbcc_area; in unicode_domain_string() local
113 *bcc_ptr = 0; in unicode_domain_string()
114 *(bcc_ptr+1) = 0; in unicode_domain_string()
117 bytes_ret = cifs_strtoUTF16((__le16 *) bcc_ptr, ses->domainName, in unicode_domain_string()
119 bcc_ptr += 2 * bytes_ret; in unicode_domain_string()
120 bcc_ptr += 2; /* account for null terminator */ in unicode_domain_string()
122 *pbcc_area = bcc_ptr; in unicode_domain_string()
129 char *bcc_ptr = *pbcc_area; in unicode_ssetup_strings() local
143 *bcc_ptr = 0; in unicode_ssetup_strings()
144 *(bcc_ptr+1) = 0; in unicode_ssetup_strings()
146 bytes_ret = cifs_strtoUTF16((__le16 *) bcc_ptr, ses->user_name, in unicode_ssetup_strings()
149 bcc_ptr += 2 * bytes_ret; in unicode_ssetup_strings()
150 bcc_ptr += 2; /* account for null termination */ in unicode_ssetup_strings()
152 unicode_domain_string(&bcc_ptr, ses, nls_cp); in unicode_ssetup_strings()
153 unicode_oslm_strings(&bcc_ptr, nls_cp); in unicode_ssetup_strings()
155 *pbcc_area = bcc_ptr; in unicode_ssetup_strings()
161 char *bcc_ptr = *pbcc_area; in ascii_ssetup_strings() local
167 strncpy(bcc_ptr, ses->user_name, CIFS_MAX_USERNAME_LEN); in ascii_ssetup_strings()
168 bcc_ptr += strnlen(ses->user_name, CIFS_MAX_USERNAME_LEN); in ascii_ssetup_strings()
171 *bcc_ptr = 0; in ascii_ssetup_strings()
172 bcc_ptr++; /* account for null termination */ in ascii_ssetup_strings()
176 strncpy(bcc_ptr, ses->domainName, CIFS_MAX_DOMAINNAME_LEN); in ascii_ssetup_strings()
177 bcc_ptr += strnlen(ses->domainName, CIFS_MAX_DOMAINNAME_LEN); in ascii_ssetup_strings()
180 *bcc_ptr = 0; in ascii_ssetup_strings()
181 bcc_ptr++; in ascii_ssetup_strings()
185 strcpy(bcc_ptr, "Linux version "); in ascii_ssetup_strings()
186 bcc_ptr += strlen("Linux version "); in ascii_ssetup_strings()
187 strcpy(bcc_ptr, init_utsname()->release); in ascii_ssetup_strings()
188 bcc_ptr += strlen(init_utsname()->release) + 1; in ascii_ssetup_strings()
190 strcpy(bcc_ptr, CIFS_NETWORK_OPSYS); in ascii_ssetup_strings()
191 bcc_ptr += strlen(CIFS_NETWORK_OPSYS) + 1; in ascii_ssetup_strings()
193 *pbcc_area = bcc_ptr; in ascii_ssetup_strings()
235 char *bcc_ptr = *pbcc_area; in decode_ascii_ssetup() local
239 len = strnlen(bcc_ptr, bleft); in decode_ascii_ssetup()
247 strncpy(ses->serverOS, bcc_ptr, len); in decode_ascii_ssetup()
252 bcc_ptr += len + 1; in decode_ascii_ssetup()
255 len = strnlen(bcc_ptr, bleft); in decode_ascii_ssetup()
263 strncpy(ses->serverNOS, bcc_ptr, len); in decode_ascii_ssetup()
265 bcc_ptr += len + 1; in decode_ascii_ssetup()
268 len = strnlen(bcc_ptr, bleft); in decode_ascii_ssetup()
280 int decode_ntlmssp_challenge(char *bcc_ptr, int blob_len, in decode_ntlmssp_challenge() argument
286 CHALLENGE_MESSAGE *pblob = (CHALLENGE_MESSAGE *)bcc_ptr; in decode_ntlmssp_challenge()
318 ses->auth_key.response = kmemdup(bcc_ptr + tioffset, tilen, in decode_ntlmssp_challenge()
663 char *bcc_ptr; in sess_auth_lanman() local
676 bcc_ptr = sess_data->iov[2].iov_base; in sess_auth_lanman()
694 memcpy(bcc_ptr, (char *)lnm_session_key, CIFS_AUTH_RESP_SIZE); in sess_auth_lanman()
695 bcc_ptr += CIFS_AUTH_RESP_SIZE; in sess_auth_lanman()
709 ascii_ssetup_strings(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_lanman()
711 sess_data->iov[2].iov_len = (long) bcc_ptr - in sess_auth_lanman()
735 bcc_ptr = pByteArea(smb_buf); in sess_auth_lanman()
742 if (((unsigned long) bcc_ptr - (unsigned long) smb_buf) % 2) { in sess_auth_lanman()
743 ++bcc_ptr; in sess_auth_lanman()
746 decode_unicode_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_lanman()
749 decode_ascii_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_lanman()
768 char *bcc_ptr; in sess_auth_ntlm() local
780 bcc_ptr = sess_data->iov[2].iov_base; in sess_auth_ntlm()
799 memcpy(bcc_ptr, ses->auth_key.response + CIFS_SESS_KEY_SIZE, in sess_auth_ntlm()
801 bcc_ptr += CIFS_AUTH_RESP_SIZE; in sess_auth_ntlm()
802 memcpy(bcc_ptr, ses->auth_key.response + CIFS_SESS_KEY_SIZE, in sess_auth_ntlm()
804 bcc_ptr += CIFS_AUTH_RESP_SIZE; in sess_auth_ntlm()
813 *bcc_ptr = 0; in sess_auth_ntlm()
814 bcc_ptr++; in sess_auth_ntlm()
816 unicode_ssetup_strings(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_ntlm()
818 ascii_ssetup_strings(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_ntlm()
822 sess_data->iov[2].iov_len = (long) bcc_ptr - in sess_auth_ntlm()
845 bcc_ptr = pByteArea(smb_buf); in sess_auth_ntlm()
852 if (((unsigned long) bcc_ptr - (unsigned long) smb_buf) % 2) { in sess_auth_ntlm()
853 ++bcc_ptr; in sess_auth_ntlm()
856 decode_unicode_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_ntlm()
859 decode_ascii_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_ntlm()
878 char *bcc_ptr; in sess_auth_ntlmv2() local
890 bcc_ptr = sess_data->iov[2].iov_base; in sess_auth_ntlmv2()
906 memcpy(bcc_ptr, ses->auth_key.response + CIFS_SESS_KEY_SIZE, in sess_auth_ntlmv2()
908 bcc_ptr += ses->auth_key.len - CIFS_SESS_KEY_SIZE; in sess_auth_ntlmv2()
921 *bcc_ptr = 0; in sess_auth_ntlmv2()
922 bcc_ptr++; in sess_auth_ntlmv2()
924 unicode_ssetup_strings(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_ntlmv2()
926 ascii_ssetup_strings(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_ntlmv2()
930 sess_data->iov[2].iov_len = (long) bcc_ptr - in sess_auth_ntlmv2()
953 bcc_ptr = pByteArea(smb_buf); in sess_auth_ntlmv2()
960 if (((unsigned long) bcc_ptr - (unsigned long) smb_buf) % 2) { in sess_auth_ntlmv2()
961 ++bcc_ptr; in sess_auth_ntlmv2()
964 decode_unicode_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_ntlmv2()
967 decode_ascii_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_ntlmv2()
987 char *bcc_ptr; in sess_auth_kerberos() local
1002 bcc_ptr = sess_data->iov[2].iov_base; in sess_auth_kerberos()
1046 *bcc_ptr = 0; in sess_auth_kerberos()
1047 bcc_ptr++; in sess_auth_kerberos()
1049 unicode_oslm_strings(&bcc_ptr, sess_data->nls_cp); in sess_auth_kerberos()
1050 unicode_domain_string(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_kerberos()
1053 ascii_ssetup_strings(&bcc_ptr, ses, sess_data->nls_cp); in sess_auth_kerberos()
1056 sess_data->iov[2].iov_len = (long) bcc_ptr - in sess_auth_kerberos()
1079 bcc_ptr = pByteArea(smb_buf); in sess_auth_kerberos()
1088 bcc_ptr += blob_len; in sess_auth_kerberos()
1096 if (((unsigned long) bcc_ptr - (unsigned long) smb_buf) % 2) { in sess_auth_kerberos()
1097 ++bcc_ptr; in sess_auth_kerberos()
1100 decode_unicode_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_kerberos()
1103 decode_ascii_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_kerberos()
1132 char *bcc_ptr; in _sess_auth_rawntlmssp_assemble_req() local
1147 bcc_ptr = sess_data->iov[2].iov_base; in _sess_auth_rawntlmssp_assemble_req()
1150 *bcc_ptr = 0; in _sess_auth_rawntlmssp_assemble_req()
1151 bcc_ptr++; in _sess_auth_rawntlmssp_assemble_req()
1153 unicode_oslm_strings(&bcc_ptr, sess_data->nls_cp); in _sess_auth_rawntlmssp_assemble_req()
1155 sess_data->iov[2].iov_len = (long) bcc_ptr - in _sess_auth_rawntlmssp_assemble_req()
1172 char *bcc_ptr; in sess_auth_rawntlmssp_negotiate() local
1231 bcc_ptr = pByteArea(smb_buf); in sess_auth_rawntlmssp_negotiate()
1241 rc = decode_ntlmssp_challenge(bcc_ptr, blob_len, ses); in sess_auth_rawntlmssp_negotiate()
1268 char *bcc_ptr; in sess_auth_rawntlmssp_authenticate() local
1333 bcc_ptr = pByteArea(smb_buf); in sess_auth_rawntlmssp_authenticate()
1341 bcc_ptr += blob_len; in sess_auth_rawntlmssp_authenticate()
1350 if (((unsigned long) bcc_ptr - (unsigned long) smb_buf) % 2) { in sess_auth_rawntlmssp_authenticate()
1351 ++bcc_ptr; in sess_auth_rawntlmssp_authenticate()
1354 decode_unicode_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_rawntlmssp_authenticate()
1357 decode_ascii_ssetup(&bcc_ptr, bytes_remaining, ses, in sess_auth_rawntlmssp_authenticate()