MikeTeo.net

A Software Technologist's Blog (Wanna Email Me?)

Archive for May, 2012

smb:// URL Support in pysmb

May-4-2012 By miketeo

Starting from pysmb version 1.0.4, application developers can utilize smb:// URLs with pysmb and urllib2 python package. One benefit from this is that if your existing application already supports downloads via other protocols like http or ftp, you can “upgrade” your application to support downloads from Windows shared folders or from Samba servers by making small modifications to your existing code.

pysmb tries to follow the smb URL scheme proposed in the IETF draft which is not much different from other standard URL schemes like http and ftp. In short, your smb URL should follow this format – smb://[<user>:<password>@]<host>[:<port>][/<share>/<path>/<filename>]

Read the rest of this entry »