Ignore:
Timestamp:
Nov 27, 2012, 4:56:06 PM (13 years ago)
Author:
Silvan Scherrer
Message:

Samba Server: updated vendor to 3.6.9

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vendor/current/source3/smbd/trans2.c

    r740 r746  
    863863                reply_outbuf(req, 10, total_sent_thistime + alignment_offset
    864864                             + data_alignment_offset);
    865 
    866                 /*
    867                  * We might have SMBtrans2s in req which was transferred to
    868                  * the outbuf, fix that.
    869                  */
    870                 SCVAL(req->outbuf, smb_com, SMBtrans2);
    871865
    872866                /* Set total params and data to be sent */
     
    10841078        }
    10851079
    1086         if (!map_open_params_to_ntcreate(smb_fname, deny_mode, open_ofun,
     1080        if (!map_open_params_to_ntcreate(smb_fname->base_name, deny_mode,
     1081                                         open_ofun,
    10871082                                         &access_mask, &share_mode,
    10881083                                         &create_disposition,
     
    22712266        struct dptr_struct *dirptr = NULL;
    22722267        struct smbd_server_connection *sconn = req->sconn;
     2268        uint32_t ucf_flags = (UCF_SAVE_LCOMP | UCF_ALWAYS_ALLOW_WCARD_LCOMP);
    22732269
    22742270        if (total_params < 13) {
     
    23142310                                goto out;
    23152311                        }
     2312                        ucf_flags |= UCF_UNIX_NAME_LOOKUP;
    23162313                        break;
    23172314                default:
     
    23312328                                    req->flags2 & FLAGS2_DFS_PATHNAMES,
    23322329                                    directory,
    2333                                     (UCF_SAVE_LCOMP |
    2334                                         UCF_ALWAYS_ALLOW_WCARD_LCOMP),
     2330                                    ucf_flags,
    23352331                                    &mask_contains_wcard,
    23362332                                    &smb_dname);
     
    46734669                case SMB_QUERY_FILE_STREAM_INFO:
    46744670                case SMB_FILE_STREAM_INFORMATION: {
    4675                         unsigned int num_streams;
    4676                         struct stream_struct *streams;
     4671                        unsigned int num_streams = 0;
     4672                        struct stream_struct *streams = NULL;
    46774673
    46784674                        DEBUG(10,("smbd_do_qfilepathinfo: "
     
    46834679                        }
    46844680
    4685                         status = SMB_VFS_STREAMINFO(
    4686                                 conn, fsp, smb_fname->base_name, talloc_tos(),
    4687                                 &num_streams, &streams);
     4681                        status = vfs_streaminfo(conn, fsp, smb_fname->base_name,
     4682                                                talloc_tos(), &num_streams, &streams);
    46884683
    46894684                        if (!NT_STATUS_IS_OK(status)) {
     
    51045099                uint32_t name_hash;
    51055100                char *fname = NULL;
     5101                uint32_t ucf_flags = 0;
    51065102
    51075103                /* qpathinfo */
     
    51155111                DEBUG(3,("call_trans2qfilepathinfo: TRANSACT2_QPATHINFO: level = %d\n", info_level));
    51165112
    5117                 if (INFO_LEVEL_IS_UNIX(info_level) && !lp_unix_extensions()) {
    5118                         reply_nterror(req, NT_STATUS_INVALID_LEVEL);
    5119                         return;
     5113                if (INFO_LEVEL_IS_UNIX(info_level)) {
     5114                        if (!lp_unix_extensions()) {
     5115                                reply_nterror(req, NT_STATUS_INVALID_LEVEL);
     5116                                return;
     5117                        }
     5118                        if (info_level == SMB_QUERY_FILE_UNIX_BASIC ||
     5119                                        info_level == SMB_QUERY_FILE_UNIX_INFO2 ||
     5120                                        info_level == SMB_QUERY_FILE_UNIX_LINK) {
     5121                                ucf_flags |= UCF_UNIX_NAME_LOOKUP;
     5122                        }
    51205123                }
    51215124
     
    51325135                                        req->flags2 & FLAGS2_DFS_PATHNAMES,
    51335136                                        fname,
    5134                                         0,
     5137                                        ucf_flags,
    51355138                                        NULL,
    51365139                                        &smb_fname);
     
    58195822        /* The set is across all open files on this dev/inode pair. */
    58205823        if (!set_delete_on_close(fsp, delete_on_close,
     5824                                 conn->session_info->security_token,
    58215825                                 &conn->session_info->utok)) {
    58225826                return NT_STATUS_ACCESS_DENIED;
     
    79767980        } else {
    79777981                char *fname = NULL;
     7982                uint32_t ucf_flags = 0;
    79787983
    79797984                /* set path info */
     
    79927997                }
    79937998
     7999                if (info_level == SMB_SET_FILE_UNIX_BASIC ||
     8000                                info_level == SMB_SET_FILE_UNIX_INFO2 ||
     8001                                info_level == SMB_FILE_RENAME_INFORMATION ||
     8002                                info_level == SMB_POSIX_PATH_UNLINK) {
     8003                        ucf_flags |= UCF_UNIX_NAME_LOOKUP;
     8004                }
     8005
    79948006                status = filename_convert(req, conn,
    79958007                                         req->flags2 & FLAGS2_DFS_PATHNAMES,
    79968008                                         fname,
    7997                                          0,
     8009                                         ucf_flags,
    79988010                                         NULL,
    79998011                                         &smb_fname);
     
    88228834        show_msg((char *)req->inbuf);
    88238835
     8836        /* Windows clients expect all replies to
     8837           a transact secondary (SMBtranss2 0x33)
     8838           to have a command code of transact
     8839           (SMBtrans2 0x32). See bug #8989
     8840           and also [MS-CIFS] section 2.2.4.47.2
     8841           for details.
     8842        */
     8843        req->cmd = SMBtrans2;
     8844
    88248845        if (req->wct < 8) {
    88258846                reply_nterror(req, NT_STATUS_INVALID_PARAMETER);
Note: See TracChangeset for help on using the changeset viewer.