Author Topic: [Python] Bind FTP to drive letter  (Read 8459 times)

0 Members and 18 Guests are viewing this topic.

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #15 on: December 17, 2011, 09:52:51 pm »
But can this work

Code: [Select]
os.system('subst V: ' + ftp.pwd())
If the server is Unix?
Because subst requires a drive letter at the beginning...

I don't know Unix,but they have no drive letter,have they?
« Last Edit: May 13, 2012, 09:29:08 pm by Area_13 »
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #16 on: December 17, 2011, 10:09:00 pm »
But can this work

os.system('subst V: ' + ftp.pwd())

If the server is Unix?
Because subst requires a drive letter at the beginning...

I don't know Unix,but they have no drive letter,have they?

That is not going to work at all. ftp.pwd() is not a valid resource to pass to subst, subst takes a URL or server address, not an FTP object or any other object or resource.
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #17 on: December 17, 2011, 10:12:03 pm »
How could I bind it with subst and the url ftp.example.com if it needs a password?
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #18 on: December 17, 2011, 10:16:07 pm »
How could I bind it with subst and the url ftp.example.com if it needs a password?

I am not sure that is possible. But you could always try the user:pass@ftp.example.com trick. ftp://username:password@ftp.example.com will(should) automatically log you in upon opening. (It might have been disabled in later versions of windows tho, I recall reading something about that somewhere.)
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #19 on: December 17, 2011, 10:28:44 pm »
subst V: ftp://myusrname:mypass@ftp.example.com doesn't work
 (names changed)
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #20 on: December 17, 2011, 10:31:13 pm »
Then subst does not support FTP. Check the URL I posted about mapping a FTP to explorer manually. I am sure you can do it programmatically if you do some research.
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #21 on: December 17, 2011, 10:34:30 pm »
It works now!

I start ftp://unsrname:pass@ftp.example.com with the browser

@ande:
thx,for the help

« Last Edit: December 17, 2011, 10:43:11 pm by Area_13 »
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #22 on: December 17, 2011, 10:42:40 pm »
But it's just a temporary solution.I'm still searching for a way to bind it to a drive letter,because it looks more professional.If someone finds a way (with python/batch) please post it.

Is there a way to say cmd ftp://... is on the internet and no local path?
« Last Edit: December 17, 2011, 10:46:23 pm by Area_13 »
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #23 on: December 17, 2011, 10:53:03 pm »
Is there a way to say cmd ftp://... is on the internet and no local path?

Could you rephrase that?
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #24 on: December 17, 2011, 11:16:02 pm »
Forget that,I wrote it without thinking before...

But is there a way to bind the FTP to a drive letter,and open it with the Fileexplorer instead of open it with the browser?

Tried it with 'net use' and 'subst' with the direct url and with a urllink on my Computer...
« Last Edit: December 17, 2011, 11:20:20 pm by Area_13 »
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #25 on: December 17, 2011, 11:43:11 pm »
Forget that,I wrote it without thinking before...

But is there a way to bind the FTP to a drive letter,and open it with the Fileexplorer instead of open it with the browser?

Tried it with 'net use' and 'subst' with the direct url and with a urllink on my Computer...

I believe that is what we have discussed the past 10 posts :P There is, manually( check the link I posted ). Programmatically, on the other hand, I dunno. But I am sure it can be done by registery and maybe some command line stuff.

Guess we gotta wait for some other guys to answer that, or you have to do the research/testing yourself.
« Last Edit: December 17, 2011, 11:44:22 pm by ande »
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #26 on: December 18, 2011, 03:50:52 pm »
Ok, I tried something and made it to open the FTP with Fileexplorer.
But how can I tell the computer to open the url ftp://usrname:pass@ftp.example.com with File Explorer instead of Internet Explorer/Firefox/etc (wich is automatically used to open it) ?
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #27 on: December 18, 2011, 04:52:48 pm »
Ok, I tried something and made it to open the FTP with Fileexplorer.
But how can I tell the computer to open the url ftp://usrname:pass@ftp.example.com with File Explorer instead of Internet Explorer/Firefox/etc (wich is automatically used to open it) ?

You write it in the address-bar? :P If you want to start it from command line, you can probably do something like "explorer ftp://usrname:pass@ftp.example.com"
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline flowjob

  • Knight
  • **
  • Posts: 327
  • Cookies: 46
  • Pastafarian
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #28 on: December 18, 2011, 04:58:39 pm »
works,thx
« Last Edit: December 18, 2011, 04:59:45 pm by Area_13 »
Quote
<phil> I'm gonna DDOS the washing machine with clothes packets.
<deviant_sheep> dont use too much soap or youll cause a bubble overflow

Offline Stackprotector

  • Administrator
  • Titan
  • *
  • Posts: 2515
  • Cookies: 205
    • View Profile
Re: [Python] Bind FTP to drive letter
« Reply #29 on: December 23, 2011, 12:28:45 am »
What about creating your own little system inspired on filesystems based on dropbox and tortoiseSVN,  they give the right mouse click extra functions, and show you what files are changed since last upload to server etc..
~Factionwars