summaryrefslogtreecommitdiff
path: root/source3/smbd/message.c
AgeCommit message (Collapse)AuthorFilesLines
2011-03-30s3: include smbd/smbd.h where needed.Günther Deschner1-0/+1
Guenther
2011-03-24charcnv: removed the allow_badcharcnv and allow_bad_conv options to ↵Andrew Tridgell1-1/+1
convert_string*() we shouldn't accept bad multi-byte strings, it just hides problems Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Thu Mar 24 01:47:26 CET 2011 on sn-devel-104
2010-01-17s3: Protect against an invalid bcc in SMBsendtxtVolker Lendecke1-1/+1
2009-12-21Remove all calls to reply_doserror - turn them intoJeremy Allison1-4/+4
correct reply_nterror calls. Next rename reply_doserror -> reply_force_doserror and plumb in when NT_STATUS_DOS is used. Jeremy.
2009-04-20Remove smb_mkstemp() - libreplace will now provide a secure mkstemp() ifJelmer Vernooij1-1/+1
the system one is broken.
2009-01-08s3:smbd: move all globals and static variables in globals.[ch]Stefan Metzmacher1-2/+1
The goal is to move all this variables into a big context structure. metze
2008-11-02Remove some direct inbuf references by adding smbreq_bufremVolker Lendecke1-2/+2
2008-11-02Simplify params of srvstr_pull_buf_talloc()Volker Lendecke1-12/+10
Now that "req" is available everywhere, use it. Rename srvstr_pull_buf_talloc() to srvstr_pull_req()
2008-11-01Remove a bunch of direct inbuf references by adding "buf" to smb_requestVolker Lendecke1-7/+7
2008-05-20Cleanup size_t return values in callers of convert_string_allocateTim Prouty1-7/+6
This patch is the second iteration of an inside-out conversion to cleanup functions in charcnv.c returning size_t == -1 to indicate failure. (This used to be commit 6b189dabc562d86dcaa685419d0cb6ea276f100d)
2008-01-04Now conn is part of smb_request, we don't need it asJeremy Allison1-4/+4
an extra parameter. This cleans up quite a few places we were passing it around without needing it. Jeremy. (This used to be commit 8f36def18e9f980e8db522e1de41e80cfd5f466e)
2007-12-09Get rid of the msgbuf[1600]Volker Lendecke1-98/+132
(This used to be commit af228007915cc8bb65fa7968da25a1a36004bc22)
2007-11-13Remove last pstring from smbd/*.cJeremy Allison1-11/+40
Jeremy. (This used to be commit f1680bada913af4eaf5c0d686983018d6c8b3e5f)
2007-10-10r24440: Convert the reply_sendXX functions to the new APIVolker Lendecke1-31/+31
(This used to be commit a64bc31098de8694b79eeafd3a226cf519700707)
2007-10-10r23784: use the GPLv3 boilerplate as recommended by the FSF and the license textAndrew Tridgell1-2/+1
(This used to be commit b0132e94fc5fef936aa766fb99a306b3628e9f07)
2007-10-10r23779: Change from v2 or later to v3 or later.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 407e6e695b8366369b7c76af1ff76869b45347b3)
2007-10-10r23726: Explicitly pass down the FLAGS2 field to srvstr_pull_buf. The nextVolker Lendecke1-4/+8
checkin will pull this up to srvstr_get_path. At that point we can get more independent of the inbuf, the base_ptr in pull_string will only be used to satisfy UCS2 alignment constraints. (This used to be commit 836782b07bf133e9b2598c4a089f1c810e4c7754)
2007-10-10r22391: Looks bigger than it is. Make "inbuf" availableJeremy Allison1-4/+4
to all callers of smb_setlen (via set_message() calls). This will allow the server to reflect back the correct encryption context. Jeremy. (This used to be commit 2d80a96120a5fe2fe726f00746d36d85044c4bdb)
2007-10-10r16945: Sync trunk -> 3.0 for 3.0.24 code. Still needJeremy Allison1-1/+2
to do the upper layer directories but this is what everyone is waiting for.... Jeremy. (This used to be commit 9dafb7f48ca3e7af956b0a7d1720c2546fc4cfb8)
2007-10-10r16397: Fix Klocwork #11767 and drasticly simplify theJeremy Allison1-153/+152
logic in smbd/process.c. All interested (Volker, Jerry, James etc). PLEASE REVIEW THIS CHANGE. The logic should be identical but *much* easier to follow and change (and shouldn't confuse Klockwork :-). Jeremy. (This used to be commit d357f8b33594472ffa78d0a112accccc2a8b1fe7)
2007-10-10r12043: It's amazing the warnings you find when compiling on a 64-bitJeremy Allison1-1/+1
box with gcc4 and -O6... Fix a bunch of C99 dereferencing type-punned pointer will break strict-aliasing rules errors. Also added prs_int32 (not uint32...) as it's needed in one place. Find places where prs_uint32 was being used to marshall/unmarshall a time_t (a big no no on 64-bits). More warning fixes to come. Thanks to Volker for nudging me to compile like this. Jeremy. (This used to be commit c65b752604f8f58abc4e7ae8514dc2c7f086271c)
2007-10-10r10656: BIG merge from trunk. Features not copied overGerald Carter1-2/+9
* \PIPE\unixinfo * winbindd's {group,alias}membership new functions * winbindd's lookupsids() functionality * swat (trunk changes to be reverted as per discussion with Deryck) (This used to be commit 939c3cb5d78e3a2236209b296aa8aba8bdce32d3)
2007-10-10r4704: Fix encoding while receiving of a message which was actually sent ↵Alexander Bokovoy1-4/+4
using STR_ASCII. Patch from Grigory Batalov <bga@altlinux.org> (This used to be commit dddd5726462c13374788713ad5ddcbdf9ee7b439)
2004-03-11Restore the contract on all convert_stringXX() interfaces. Add a ↵Jeremy Allison1-1/+1
"allow_bad_conv" boolean parameter that allows broken iconv conversions to work. Gets rid of the nasty errno checks in mangle_hash2 and check_path_syntax and allows correct return code checking. Jeremy. (This used to be commit 7b96765c23637613f079d37566d95d5edd511f05)
2003-08-20Attempt to fix the charcnv issues causing nmbd to crash. If we get a failedJeremy Allison1-1/+1
conversion simply copy as is. Also fixed the horrid malloc-twice-copy code in the convert alloc path. Jeremy. (This used to be commit cfde7477fd12caef943a9422b52174438092a135)
2003-03-20Patch from Samuel Thibault to convert messages from dos to unix charsetJelmer Vernooij1-9/+18
when sending(and vice versa when receiving). (This used to be commit 5310447ec6e0df1c000e3ee14572f5b7fee31f28)
2002-07-15updated the 3.0 branch from the head branch - ready for alpha18Andrew Tridgell1-5/+5
(This used to be commit 03ac082dcb375b6f3ca3d810a6a6367542bc23ce)
2002-01-30Removed version number from file header.Tim Potter1-2/+1
Changed "SMB/Netbios" to "SMB/CIFS" in file header. (This used to be commit 6a58c9bd06d0d7502a24bf5ce5a2faf0a146edfa)
2001-12-06again an intrusive patch:Jean-François Micouleau1-1/+3
- removed the ugly as hell sam_logon_in_ssb variable, I changed a bit the definition of standard_sub_basic() to cope with that. - removed the smb.conf: 'domain admin group' and 'domain guest group' parameters ! We're not playing anymore with the user's group RIDs ! - in get_domain_user_groups(), if the user's gid is a group, put it first in the group RID list. I just have to write an HOWTO now ;-) J.F. (This used to be commit fef52c4b96c987115fb1818c00c2352c67790e50)
2001-10-02Removed 'extern int DEBUGLEVEL' as it is now in the smb.h header.Tim Potter1-3/+0
(This used to be commit 2d0922b0eabfdc0aaf1d0797482fef47ed7fde8e)
2001-08-27converted smbd to use NTSTATUS by defaultAndrew Tridgell1-4/+4
major changes include: - added NSTATUS type - added automatic mapping between dos and nt error codes - changed all ERROR() calls to ERROR_DOS() and many to ERROR_NT() these calls auto-translate to the client error code system - got rid of the cached error code and the writebmpx code We eventually will need to also: - get rid of BOOL, so we don't lose error info - replace all ERROR_DOS() calls with ERROR_NT() calls but that is too much for one night (This used to be commit 83d9896c1ea8be796192b51a4678c2a3b87f7518)
2001-07-04The big character set handling changeover!Andrew Tridgell1-5/+4
This commit gets rid of all our old codepage handling and replaces it with iconv. All internal strings in Samba are now in "unix" charset, which may be multi-byte. See internals.doc and my posting to samba-technical for a more complete explanation. (This used to be commit debb471267960e56005a741817ebd227ecfc512a)
2001-06-23Added other_safe_chars to alpha_strcpy(). Needs testing but is a betterJeremy Allison1-2/+2
fix for the problem. Jeremy. (This used to be commit e059fffd03a1382fb2b7059b6de369d9fc765a17)
2001-06-21Following info from TAKAHASHI Motonobu <monyo@samba.gr.jp>,Jeremy Allison1-3/+2
Samba Users Group Japan, ensure that we don't use dos_to_unix(xx,True), but always use dos_to_unix(xx,False) to prevent overwriting. Jeremy. (This used to be commit 244aec8ea623fec828add3ab09c5003bf32bd5c7)
2001-04-13Merge of Andrew's changes in 2.2.Jeremy Allison1-1/+1
Jeremy. (This used to be commit fc76681812b1469208ad6c8847afdfc68bc6db49)
2001-04-13As Andrew suggested, make smbrun return a fd for a deleted file which can thenJeremy Allison1-1/+1
be read. Jeremy. (This used to be commit e7d59d6de89a5fdd201e4b5c6072dab08b1519db)
2001-04-11To stop people complaining about the mktemp call, move it into lib/util.c. ↵Jeremy Allison1-6/+5
Thanks to Andrew for all this code. Fixed extra line in lib/sysacls.c that broke XFS ACL code. Jeremy. (This used to be commit 9b32b8a8cfc8ddb93c14d5581f433d2e93f89ed2)
2001-03-14converted the smb messaging code to unicodeAndrew Tridgell1-17/+15
(This used to be commit 54bde1b3aec829ba55b8a6c946424fdaf38803a9)
2001-03-11Merge of new 2.2 code into HEAD (Gerald I hate you :-) :-). Allows new SAMRJeremy Allison1-4/+0
RPC code to merge with new passdb code. Currently rpcclient doesn't compile. I'm working on it... Jeremy. (This used to be commit 0be41d5158ea4e645e93e8cd30617c038416e549)
2000-10-11changes to sync with 2.2. treeHerb Lewis1-4/+20
.cvsignore remove config.h - not in this directory include/profile.h profile changes lib/messages.c added message to return debug level libsmb/clierror.c cast to get rid of compiler warning libsmb/smbencrypt.c cast to get rid of compiler warning profile/profile.c add flush profile stats changes for profile struct rpc_parse/parse_samr.c fix for compiler warning rpc_server/srv_samr.c cast to get rid of compiler warning smbd/ipc.c profile stats message.c profile stats smbd/negprot.c profile stats smbd/nttrans.c profile stats smbd/trans2.c profile stats utils/smbcontrol.c new flush stats command (This used to be commit bbb24daa25dca4e4b6b1f8942cd84ee3aa1bed8e)
2000-05-10more merging voodooAndrew Tridgell1-0/+4
this adds "#define OLD_NTDOMAIN 1" in lots of places. Don't panic - this isn't permanent, it should go after another few merge steps have been done (This used to be commit 92109d7b3c06f240452d39f669ecb8c9c86ab610)
2000-01-27Fixed code page conversions of messages outgoing/incoming.Jeremy Allison1-0/+10
Jeremy. (This used to be commit 84b045cbc8b337f1e23f200af433ac9d265a22d4)
1999-12-13first pass at updating head branch to be to be the same as the SAMBA_2_0 branchAndrew Tridgell1-8/+12
(This used to be commit 453a822a76780063dff23526c35408866d0c0154)
1998-11-17Added the same open()/fopen()/creat()/mmap() -> sys_XXX calls.Jeremy Allison1-1/+1
Tidied up some of the mess (no other word for it). Still doesn't compile cleanly. There are calls with incorrect parameters that don't seem to be doing the right thing. This code still needs surgery :-(. Jeremy. (This used to be commit 18ff93a9abbf68ee8c59c0af3e57c63e4a015dac)
1998-08-14this is the bug change to using connection_struct* instead of cnum.Andrew Tridgell1-6/+10
Connections[] is now a local array in server.c I might have broken something with this change. In particular the oplock code is suspect and some .dll files aren't being oplocked when I expected them to be. I'll look at it after I've got some sleep. (This used to be commit c7ee025ead4a85b6fa44a832047b878451845fb6)
1998-07-31As per a Andrew's message, I went through and removed the timestring()Christopher R. Hertel1-4/+4
timestamps from several DEBUG messages. The timestamps are redundant now that DEBUG() provides them automatically. There are still a few more files to do, but I've got to get home for dinner. Chris -)----- (This used to be commit 60286ccecaa6028d687e6406755016455e3b3a26)
1998-05-11changed to use slprintf() instead of sprintf() just aboutAndrew Tridgell1-1/+1
everywhere. I've implemented slprintf() as a bounds checked sprintf() using mprotect() and a non-writeable page. This should prevent any sprintf based security holes. (This used to be commit ee09e9dadb69aaba5a751dd20ccc6d587d841bd6)
1998-05-07This should (hopefully :-) be the final fix for the %U %G substitutionJeremy Allison1-1/+1
problem.... smbpass.c: Removed Luke's dire warning - as some of the functions in here *need* to be called externally :-). Jeremy. (This used to be commit 1fd8d12ca414066acec71b33eb8a13e16c2acd3a)
1998-05-06Fixes for the %U and %G problems people have reported.Jeremy Allison1-1/+1
Essentially, multiple session_setup_and_X's may be done to an smbd. As there is only one global variable containing the requested connection name (sessionsetup_user), then any subsequent sessionsetups overwrite this name (causing %U and %G to get the wrong name). This is particularly common when an NT client does a null session setup to get a browse list after the user has connected, but before a share has been mounted. These changes store the requested_name in the vuid structure (so this only really works for user level and above security) and copies this name back into the global variable before the standard_sub call. Jeremy. (This used to be commit b5187ad6a3b3af9fbbeee8bced0ab16b41e9825b)
1998-04-13Changes to allow Samba to be compiled with -Wstrict-prototypesJeremy Allison1-4/+4
with gcc. (Not a big change although it looks like it :-). Jeremy. (This used to be commit cd2613c57261456485fe4eeecfda209ada70de8e)