1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

256 Commits

Author SHA1 Message Date
Richard Sharpe
0ea6c2473b Improve the sample GTK+ client program to make it a bit more functional.
(This used to be commit 3e8366c58c)
2001-02-19 02:19:03 +00:00
Jeremy Allison
fd46817f0b Excise snprintf -> slprintf.
srv_samr.c: duplicate gid fix.
srv_spoolss_nt.c: Merge of JF's work.
uid.c: Fix for returning names when a PDC.
Jeremy.
(This used to be commit d938ad6963)
2001-02-16 19:21:18 +00:00
Richard Sharpe
b4b387e31b Fix calls to smbc_init in testsmbc.c and tree.c
(This used to be commit 244edad065)
2001-02-12 12:31:05 +00:00
Anton Blanchard
c15a054b21 io_bufsize was set too large and so full length reads
and writes got broken up into one ~64k and one ~1k packet.
(This used to be commit b91f906467)
2001-01-25 06:40:44 +00:00
Richard Sharpe
552d6bce08 Fixed bugs relating to Win2K and the need for a codepage so that unicode
strings can be handled correctly.
(This used to be commit 5629b097d4)
2001-01-14 00:11:29 +00:00
Richard Sharpe
fb40134446 Many bug fixes to the libsmbclient.c code plus
- an implementation of smbc_readdir
  - extensions to tree.c to show files in a second window
  - changes to auth_fn to provide buffers for username, password, etc
    from caller rather than callee
(This used to be commit 7f559c1a73)
2001-01-12 05:10:45 +00:00
Richard Sharpe
e646dddfde Update the tree.c GTK+ App so it can walk down directories etc ...
(This used to be commit 0490a0ed10)
2001-01-07 12:54:03 +00:00
Richard Sharpe
34fea75f35 Fix some more bugs in libsmbclient.c and add functionality to tree.c
(This used to be commit d6cef8877a)
2001-01-06 14:48:55 +00:00
Richard Sharpe
a0feaf62b7 Fix a minor problem with listing servers in a workgroup and add a
gtk+ test application that tests out some of this stuff ...
(This used to be commit 606c4aecea)
2001-01-06 12:15:46 +00:00
Richard Sharpe
b6e811b90b The latest changes to libsmbclient ...
It can now do a directory listing for workgroups, servers, and shares, and,
with a bit more effort, it will be able to list directories and files.

I also does not request a username and password for the IPC$ share, but it
should if the first attempt to connect fails.
(This used to be commit 38ff91c505)
2001-01-05 13:43:19 +00:00
Richard Sharpe
dca808cbc4 Needed a callback arg on cli_list ...
(This used to be commit d45e667a74)
2001-01-05 13:11:29 +00:00
Richard Sharpe
92ebc81734 I need a callback arg for cli_NetServerEnum and cli_RNetShareEnum, so I had
to modifiy any routine that calls it to pass NULL and so forth.

Should have no impact. It compiles OK.
(This used to be commit 7f862e387f)
2001-01-04 11:35:55 +00:00
Richard Sharpe
b87c484051 First pass at the libsmbclient code ...
This code handles the basic stuff and compiles and links under Linux, but
I do not know about any other operating systems. Now onto directory
listing routines, including those that list workgroups, servers, etc.

Nothing is built automatically yet, you have to make client/testsmbc to build
the library and test program. Also, no make install targets are defined for
libsmbclient.so as yet, either.

Would be good if people test on operating systems other than Linux.
(This used to be commit 51c0436a50)
2000-12-26 05:57:10 +00:00
Jeremy Allison
8d26523e90 Tar fixes from Craig Barratt craig@arraycomm.com.
Jeremy.
(This used to be commit cf05709ec3)
2000-11-22 23:06:29 +00:00
Gerald Carter
cb55856e4e fixed typo
jerry
(This used to be commit d2949468dc)
2000-09-14 16:47:49 +00:00
Gerald Carter
28c07a5e9f added -A <authfile> option to smbclient for the reading of username /
password credentials from a file.



--jerry
(This used to be commit e291500903)
2000-08-29 14:35:31 +00:00
Andrew Tridgell
8843a6379d Linux kernel oplocks now seem to work, but need a _lot_ of testing
I had to modify sys_select() to not loop on EINTR. I added a wrapper
called sys_select_intr() which gives the old behaviour.
(This used to be commit b28cc4163b)
2000-06-11 05:57:58 +00:00
Andrew Tridgell
88a97957e7 and yet another memory leak - this one in the client
(This used to be commit a85ae6e0ae)
2000-05-02 07:50:33 +00:00
Jeremy Allison
693ffb8466 Added sys_fork() and sys_getpid() functions to stop the overhead
of doing a system call every time we want to just get our pid.
Jeremy.
(This used to be commit 148628b616)
2000-05-02 02:23:41 +00:00
Andrew Tridgell
700f72453e - removed all our old wildcard matching code and replaced it with a
call to ms_fnmatch(). This also removes all the Win9X semantics stuff
and a bunch of other associated cruft.

- moved the stat cache code into statcache.c

- fixed the uint16 alignment requirements of ascii_to_unistr() and
  unistr_to_ascii()

- trans2 SMB_FIND_FILE_BOTH_DIRECTORY_INFO returns the short name as
  unicode always (at least thats what NT4 does)

- fixed some errors in the in-memory tdb code. Still ugly, but doesn't
  crash as much
(This used to be commit 03e9cea004)
2000-04-30 11:04:28 +00:00
Jeremy Allison
d56e3425a1 Fix for names with spaces and some I18N filename issues from
V. Fyodorov <V.Fyodorov@VAZ.RU>.
Jeremy.
(This used to be commit 4673aa1a4b)
2000-03-10 22:25:02 +00:00
Jeremy Allison
0f1eee5c7a client/client.c:
libsmb/clientgen.c: Fixes for Win2k smbclient browsing.
Other fixes implement smbpasswd -x user to delete users. Also allows swat
to do the same.
Jeremy.
(This used to be commit 9f6ad04676)
2000-02-25 22:25:25 +00:00
Jeremy Allison
451dcb3351 Fixed code page conversions of messages outgoing/incoming.
Jeremy.
(This used to be commit 84b045cbc8)
2000-01-27 01:09:21 +00:00
Jeremy Allison
d867b86721 Second set of inline optimisation fixes from Ying Chen <ying@almaden.ibm.com>.
Stop makeing function calls for every use of skip_multibyte_char. This function
is called several *million* times during a NetBench run :-).
Jeremy.
(This used to be commit e5a3deba46)
2000-01-26 00:12:35 +00:00
Andrew Tridgell
e8b5cb4515 cli_open() wasn't handling DENY_FCB or O_WRONLY correctly.
After fixing that I needed to use O_RDWR instead of O_WRONLY in
several places to avoid the silly bug in MS servers that doesn't allow
getattrE on a file opened with O_WRONLY
(This used to be commit e21aa4cb08)
2000-01-08 10:15:53 +00:00
Andrew Tridgell
171da4d787 this looks like a big commit, but it isn't really :)
This fixes our netbios scope handling. We now have a 'netbios scope' option
in smb.conf and the scope option is removed from make_nmb_name()

this was prompted by a bug in our PDC finding code where it didn't append
the scope to the query of the '*' name.
(This used to be commit b563be824b)
2000-01-07 06:55:36 +00:00
Jeremy Allison
20bd653b48 Fixed spurious error message when doing a 'put' of an empty file.
Jeremy
(This used to be commit 9ba8ad1d3d)
2000-01-06 21:23:49 +00:00
Jeremy Allison
c4914e2202 client/client.c: I18N fixes.
smbd/dir.c: Reformatting comments.
smbd/ipc.c: New password change code for Win98.
Jeremy.
(This used to be commit 9e90122afd)
2000-01-05 19:59:42 +00:00
Andrew Tridgell
3da55bfb8e changed %g to %3.1f to be friendly to our poor snprintf() code
(This used to be commit 6d506ee641)
1999-12-21 09:54:24 +00:00
Andrew Tridgell
a0b9e3ef4f client/smbspool.c from 2.0.6
(This used to be commit 599a7e7f9e)
1999-12-17 01:48:16 +00:00
Andrew Tridgell
32a965e09c 2nd phase of head branch sync with SAMBA_2_0 - this delets all the files that were in the head branch but weren't in SAMBA_2_0
(This used to be commit d7b2087865)
1999-12-13 13:35:20 +00:00
Andrew Tridgell
3db52feb1f first pass at updating head branch to be to be the same as the SAMBA_2_0 branch
(This used to be commit 453a822a76)
1999-12-13 13:27:58 +00:00
Luke Leighton
6ddfc68e04 sys_select added one more argument (read, write selectors).
(This used to be commit e4d92ff9df)
1999-12-01 02:15:14 +00:00
Luke Leighton
9b68305475 whoa. _major_ restructure of rpcclient. fixed some buuugs, created a few.
found out that getopt() _must_ have optind set to 0 before reuse.

still haven't decided what to do with the net* api yet...
(This used to be commit 29c480085e)
1999-11-26 23:04:19 +00:00
Luke Leighton
eae9b12ca5 general, drastic improvements to rpcclient.
added samgroup <groupname> command
added samgroupmem <groupname> command

added proper registry key completion

added sam command user-completion (e.g samuser [tab])

added sam command group-completion (e.g samgroup [tab])
(This used to be commit bc5d021916)
1999-10-30 20:32:40 +00:00
Tim Potter
59bd1de1a5 Put back in GNU readline support for smbclient accidentally trashed by
tridge in the clientgen.c to clientutil.c conversion.
(This used to be commit 26d66071fb)
1999-07-09 03:34:09 +00:00
Luke Leighton
8e14594798 smbclient modified to use cli_establish_connection(). smbclient therefore
now uses improved authentication.  smbclient now "broken" for "scripts"
based on DEBUG() output.  cli_establish_connection() requires modification
to support old scripts.
(This used to be commit b0539d4340)
1999-06-29 19:39:23 +00:00
Alexandre Oliva
a8aff598f4 declare ttarf as double, as in client.c
(This used to be commit dfcfeb743a)
1999-03-30 10:41:07 +00:00
Alexandre Oliva
d963fb524c use double instead of SMB_BIG_UINT for dir_total and ttarf
(by tridge, merged from branch)
(This used to be commit b482ac8fc4)
1999-03-30 10:25:20 +00:00
Luke Leighton
754be76bde SMB_BIG_INT dir_total incompatible with %d: must use %llu (line 446)
(This used to be commit 1cece21246)
1999-03-25 21:01:08 +00:00
Alexandre Oliva
1db113b0a2 * client/client.c (dir_total): use SMB_BIG_UINT
* client/clitar.c (ttarf): ditto
* * lib/snprintf.c: support long longs; adapted from Cloyce D. Spradling's
patch <cloyce@headgear.org>
(This used to be commit 29581f8486)
1999-03-25 20:21:01 +00:00
Michael Warfield
894a824041 Got to the bottom of another weird one...
Piping the output of smbmount back to autofs/automount was causing the
automount process to hang.  Reason was that automount was depending
on the pipe to close to continue on, rather than detecting the child
signal.  This occured with debug enabled and the daemon process was not
closing the stdout process.  Disabling debuging avoids the problem.
Debugging is turned off in the cvs repository and a warning placed over
the debugging option.
(This used to be commit 329ceaee49)
1999-02-18 04:33:06 +00:00
Michael Warfield
e588ffdaa8 Added caching of user password if it was entered via getpass. We were already
caching the password if it came from the command line or from the environment.
This completes the set and deals with the bloody nusance when reconnecting
a connection after we have gone daemon...  Grrr...

Added code to clean up the mount point following a catastrophic failure
during reconnect.  The smbmount daemon was exiting but leaving the mount
point in an unusable state.  If smbmount must exit following a reconnect
failure, we "unmount" the mount point and clean up mnttab.  Currently,
the unmount works, fixing some really ugly I/O errors and failure when
trying to remount.  The cleanup on mnttab still has problems.  This
is better than what it was and doesn't break anything that wasn't broken
before, so I'm committing this in even with the mnttab problem.  Will
commit the fix to that when I figure out what is busted there...

	-mhw-
(This used to be commit ad8389804c)
1999-02-14 23:15:54 +00:00
Michael Warfield
cbbac5455c Fixed a glibc glitch in smbumount.c and reenabled some debugging
in smbmount.c
(This used to be commit 4b4a706213)
1999-02-13 18:36:49 +00:00
Luke Leighton
91403ea47d %s not $s
(This used to be commit 62118e15fe)
1999-02-03 16:30:54 +00:00
Michael Warfield
8fdc846070 Minor change to bring smbmount in the main branch in line with some bzero
to memset changes...
(This used to be commit 1cb8fcb33b)
1999-02-01 22:01:29 +00:00
Michael Warfield
f5ac863e5a Ok... Yet another round of fixes for smbmount and autofs.
1)  The earlier fix for the smbmount race conditions broke the PID
	registration with smbfs.  That fix has been backed out and
	replaced by a signalling convention from the child smbmount
	process back to the parent telling the parent when it is safe
	to exit.

2)  Fixing all of this uncovered a NASTY deadly embrace between smbmount,
	smbmnt, and autofs.  This was caused by the setsid call in the
	daemon code.  The smbmnt process no longer was registered as
	"magic" because it was no longer in the autofs process group.
	Many many kudos and thanks to H Peter Anvin for giving me the
	clue to solving this agravating puzzle.  The setsid was moved
	down the where the child signals the parent and a warn left in
	its place in the daemonize code.

3)  Fixed (actually worked around with a BUTT UGLY HACK) a problem with
	SMB_GET_MOUNTPID in smbumount.c.  The smb_fs.h header file has
	the parameter to this ioctl defined as a uid_t.  Unfortunately
	that's a 32 bit quantity under glibc and it's currently a 16 bit
	quantity in kernel space.  Undefined the macro and redefined
	it with a parameter of __kernel_uid_t.  That should keep us
	out of trouble till I can have someone fix smb_fs.h in the
	kernel sources...
(This used to be commit c5608093e4)
1999-01-31 21:28:55 +00:00
Luke Leighton
f6c646467d set_port warning / unused / global/local variable overlap issues
cmd_svcctl.c tests got put into cvs by mistake.
(This used to be commit 0ed70972d7)
1999-01-27 19:37:29 +00:00
Richard Sharpe
f5f913b001 Putting back the -p flag in smbclient.
However, it seems that the -s flag
in smbclient is also ignored :-(
(This used to be commit f6c7819266)
1999-01-25 01:46:14 +00:00
Richard Sharpe
8dac09c5a1 A small change to clitar.c (really, I promise :-)
If we are writing the tar file to stdout, set dbf to stderr
so that we do not screw up tar output with log info etc.

Compiles clean and tested with 38MB backup. Honest :-)
(This used to be commit 57301a3eb4)
1999-01-17 01:03:52 +00:00