0

The Samba server is running on Linux, the clients are Windows machines (Windows XP and Windows 7). Is it possible to extend the client-side context menus for files and folders on the mounted shares, by configuring something on the server-side smb.conf?

I need this so clients can easily initiate commands to be run on the server side, on shared files. For example, if I have a server-side .mobi-to-.epub converter, I'd like to add a context menu command Convert to EPUB, which can be initiated on the client (by clicking on an item in the context menu), and it would run on the server on the file(s) selected.

If this is not possible just by changing smb.conf, what's the easiest way? I'm considering binding plink.exe (from PuTTY) to a command on the local context menu, but that introduces key management issues (I'd like to reuse the Samba authentication), and I suspect that there will be problems with filenames with funny (e.g. accented or whitespace) characters. Is there anything better?

pts
  • 425
  • 1
  • 5
  • 15
  • The r-click menus would be on the windows side, not the Samba side. To test this, you should be able to drop a .zip or .cab file and extract that with plain jane windows. Add WinZip or WinRAR and it will give you additional options. So you would need to add the apps to the client side and make sure windows can match the file extension to be able to link top the files and process them. – MikeAWood Apr 01 '14 at 00:40
  • @MikeAWood: Is there a way to configure something on the Samba side, and make Windows pick it up as client-side changes when the share is mounted? (It doesn't have to be fully automatic, a few extra clicks by the user after the mount are OK.) – pts Apr 03 '14 at 21:31
  • not that I know of. you can't change the menus within windows like that as it would be a huge security exploit. The menus are built based on registry entries based on the file's extension (or the fact it is a folder or drive or other object). Besides, even if you were able to change it, the application would still need to be installed on the workstation so it knew WHAT to do with the file/folder/object once you r-clicked and then selected it. You could push registry changes out via something like psexec, but you'd still be missing the application... What are you trying to solve? – MikeAWood Apr 03 '14 at 23:38
  • @MikeAWood: About what I am trying to solve: see the *Convert to EPUB* functionality in the question. Please note that there is no need to install an application to the Windows client, because the actual conversion would be run on the server side. All I need is an client-to-server-custom-RPC mechanism over Samba which can be instantiated on selected files from the context menu on the client. – pts Apr 04 '14 at 14:41
  • Since Windows context menu is a locally based mechanism, what you are asking for isn't possible without having something on the workstation even if it is nothing more than a trigger to have the server handle the request for the user. SMB simply doesn't work like that. At least not on Windows. There is no "trigger" that I am aware of that would let you do what you are asking. – MikeAWood Apr 04 '14 at 22:40

0 Answers0