Re: Porting guide Samba 2.2.x - 3.0
[follow-up myself .. :) ] unfortunately I wasn't able to follow the 3.0 development nor this ML very closely. Does a porting guide from 2.2.x to 3.0 exist? I've just discovered that the following code void send_message(pstring msg) { [..] unix_to_dos(msg); len = strlen(msg); if (!cli_message_start(cli, remote_machine, username, grp_id)) { DEBUG(0,(message start: %s, cli_errstr(cli))); return; } [..] I fixed it this way, it works with Samba 3.0 alpha21, but probably not the best way :) [..] #if SAMBA_VERSION_MAJOR==3 fstrcpy(remote_machine, get_remote_machine_name()); DEBUG(5, (remote machine is: %s\n, remote_machine)); #endif [..] #if SAMBA_VERSION_MAJOR==2 pstrcpy(msg_conv, unix_to_dos(msg)); #elif SAMBA_VERSION_MAJOR==3 push_ascii_pstring(msg_conv, msg); #endif Hm, still I have to figure out, how a newline has to be encoded correctly, as the winpop pane of Win98 shows text1|text2 instead of text1 text2. best regards, Rainer Link
Porting guide Samba 2.2.x - 3.0
Folks, unfortunately I wasn't able to follow the 3.0 development nor this ML very closely. Does a porting guide from 2.2.x to 3.0 exist? I've just discovered that the following code void send_message(pstring msg) { [..] unix_to_dos(msg); len = strlen(msg); if (!cli_message_start(cli, remote_machine, username, grp_id)) { DEBUG(0,(message start: %s, cli_errstr(cli))); return; } [..] does not compile anymore with Samba 3.0 alpha 20, as the unix_to_dos function seems to be removed. Any equivalent available? Thanks! best regards, Rainer Link OpenAntiVirus.org
Re: VFS Virus Scanner idea...
On Thu, Sep 12, 2002 at 10:54:39PM +0200, Juergen Hasch wrote: It's also interesting that you can download the scan engine and the virus signature data base from trend micro and use it with the Samba VFS module without even buying their product :-) I found no indication on their website if this is legal or not... Ask a representative of Trend Micro :) Actually, I'd like to point out that when using samba-vscan please make sure you've purchased the correct license. Some AV companies prohibit the use of a workstation version on a server. Or if you purchased a 10-user license, but your Samba server serves say 100 users, this would violate the license, too. Thanks. best regards, Rainer Link
Re: VFS Virus Scanner idea...
On Thu, Sep 12, 2002 at 04:47:58PM -0400, [EMAIL PROTECTED] wrote: Point #2 - Server side anti-virus is a good thing, but is not a substitute for client side anti-virus. Don't think for a moment that you're safe from viruses because your server is running AV software. I'm a friend of the client-server based virus protection approach, that's one of the main reasons why I wrote samba-vscan (which I actually don't need on my own, as I don't have any windows clients at all). And, uhm, virus scanning has never a detection rate of 100%. Point #3 - In some ways I think server side anti-virus is pointless. It does prevent the sharing of viruses through the server, which is where it *is* useful. At the same time, if the goal is to prevent viruses from wiping out the data you have on your servers, server side AV doesn't protect you. Any connected workstation can get infected with a virus that deletes every server based file it has authorization to delete. Thus the server side AV only gives the illusion of protection. Hum, client-based av software won't help here in all cases (think of a new virus). One big part of anti-virus strateg must be backups :) [which does not mean backups are only needed because of viruses - data loss because of hardware failure or by mistake are much more frequent]. Another important part is user education, but this is beyond the scope of this mailing list. best regards, Rainer Link
Re: Auditing with VFS
Daniel Niasoff schrieb: When auditing with VFS the pathname recorded is only the relative path for the share not the the full path all the way from root. int audit_close(struct files_struct *fsp, int fd) [..] fstrcpy(fname, fsp-conn-connectpath); fstrcat(fname, /); fstrcat(fname, fsp-fsp_name); [..] Should work. HTH best regards, Rainer Link -- Rainer Link | Student of Computer Networking [EMAIL PROTECTED] | University of Applied Sciences, Furtwangen, Germany rainer.w3.to | http://www.computer-networking.de/
Re: VFS - fsp-prev - Is this usable? ( first write issue to a file)
Everytime I use this the VFS object crashes. Even if I check for NULL first... I would to use this to see if the fsp call was for the same filename fsp-prev-fsp_name is this right? Not sure if I got your point. Anyway, I had once the situation fsp-fsp_name was always NULL. As my kernel supports LFS, Samba was compiled with LFS, too. Therefore, my module has to be compiled with -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 and since then fsp-fsp_name actually contains the file name. HTH best regards, Rainer Link -- Rainer Link | Member of Virus Help Munich (www.vhm.haitec.de) [EMAIL PROTECTED] | Member of AMaViS Development Team (amavis.org) rainer.w3.to | OpenAntiVirus Project (www.openantivirus.org)
Re: VFS Programming Docs.
Jason C. Leach schrieb: hi, I'm in need of some VFS programming dos. I'd like to program a VFS modules that will retrieve an archive (tar.gz) and decompres it when somone tries to access a specific file type. Or something similar. Once I see how complicated, I'll decide. The only documentation I'm aware of is http://www.geocities.com/orville_torpid/papers/vfs_tutorial.html But it's somewhat out-of-date IIRC. Just do a RTFS :) in examples/VFS of the Samba sources. HTH best regards, Rainer Link -- Rainer Link | Student of Computer Networking [EMAIL PROTECTED] | University of Applied Sciences, Furtwangen, Germany rainer.w3.to | http://www.computer-networking.de/
Re: VFS: hocking close call ... (Samba 2.2.2)
Rainer Link schrieb: I have a VFS-related question. My current (somehwat ugly) just-for-debugging code looks like this: int vscan_close(struct files_struct *fsp, int fd) { [..] } Unfortunately, fsp-fsp_name is always NULL. Here's the snippet from [..] Actually, just for the record. This happens, if -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 is missing in the Makefile on a system, which has LFS support :) With those flags added to CFLAGS, everything works as expected. So, let's write some code for samba-vscan to do virus scanning via close call :) cheers, Rainer -- Rainer Link | Student of Computer Networking [EMAIL PROTECTED] | University of Applied Sciences, Furtwangen, Germany rainer.w3.to | http://www.computer-networking.de/
Re: VFS modules patches for 2.2 CVS
Lars Mueller schrieb: Hi, I've attched a patch for the examples/VFS modules of 2.2 CVS to build all modules successful. Hm, if -D_LARGEFILE64_SOURCE is set probably -D_FILE_OFFSET_BITS=64 should be set, too. I wrote a qd Makefile.in for examples/VFS, so that Makefile is generated by ./configure, which sets CFLAGS correctly (i.e. if popt is not installed as lib, sources/popt is used). But let's wait for libmaker ... :) cheers, Rainer -- Rainer Link | Student of Computer Networking [EMAIL PROTECTED] | University of Applied Sciences, Furtwangen, Germany rainer.w3.to | http://www.computer-networking.de/