Ivars 6 years ago
parent
commit
eb74cc0a47
4 changed files with 16 additions and 17 deletions
  1. 9
    9
      file.py
  2. 5
    5
      project.wpr
  3. 1
    2
      sources/config.py
  4. 1
    1
      sources/viaplay.py

+ 9
- 9
file.py View File

226
 
226
 
227
 if __name__ == "__main__":
227
 if __name__ == "__main__":
228
     res = join("aaa", "bbb")
228
     res = join("aaa", "bbb")
229
-    #url = "smb://user:Kaskade7@192.168.77.197/hdd/test"
230
-    url = "ftp://user:Kaskade7@home.blue.lv:21/hdd/test"
231
-    url = "ftp://user:Kaskade7@192.168.77.197:21/hdd/test"
229
+    #url = "smb://user:xxxx@192.168.77.197/hdd/test"
230
+    url = "ftp://user:xxxx@home.blue.lv:21/hdd/test"
231
+    url = "ftp://user:xxxx@192.168.77.197:21/hdd/test"
232
 
232
 
233
-    mkdir("ftp://user:Kaskade7@192.168.77.197:21/hdd/movie/AAA")
234
-    res = listdir("ftp://user:Kaskade7@home.blue.lv/hdd/movie/")
233
+    mkdir("ftp://user:xxxx@192.168.77.197:21/hdd/movie/AAA")
234
+    res = listdir("ftp://user:xxxx@home.blue.lv/hdd/movie/")
235
     print res
235
     print res
236
-    rmdir("ftp://user:Kaskade7@192.168.77.197:21/hdd/movie/AAA")
237
-    rename("ftp://user:Kaskade7@192.168.77.197:21/hdd/test", "ftp://user:Kaskade7@192.168.77.197:21/hdd/test2")
238
-    remove("ftp://user:Kaskade7@192.168.77.197:21/hdd/test2")
239
-    e = isdir("ftp://user:Kaskade7@192.168.77.197:21/hdd/movies/TV2")
236
+    rmdir("ftp://user:xxxx@192.168.77.197:21/hdd/movie/AAA")
237
+    rename("ftp://user:xxxx@192.168.77.197:21/hdd/test", "ftp://user:xxxx@192.168.77.197:21/hdd/test2")
238
+    remove("ftp://user:xxxx@192.168.77.197:21/hdd/test2")
239
+    e = isdir("ftp://user:xxxx@192.168.77.197:21/hdd/movies/TV2")
240
     print e
240
     print e
241
 
241
 
242
     f = open(url, "wb")
242
     f = open(url, "wb")

+ 5
- 5
project.wpr View File

33
         (u'https://walterebert.com/playground/video/hls/sintel-trailer.m3u8',
33
         (u'https://walterebert.com/playground/video/hls/sintel-trailer.m3u8',
34
          '')),
34
          '')),
35
                       loc('run.py'): ('project',
35
                       loc('run.py'): ('project',
36
-                                      (u'config::home  ftp://user:Kaskade7@home.blue.lv/hdd/streams.cfg',
36
+                                      (u'config::home  ftp://user:xxxx@home.blue.lv/hdd/streams.cfg',
37
                                        '')),
37
                                        '')),
38
                       loc('sources/lmt.py'): ('project',
38
                       loc('sources/lmt.py'): ('project',
39
         (u'home',
39
         (u'home',
261
         u'--slud'],
261
         u'--slud'],
262
                          loc('kivy_test.py'): [u'https://walterebert.com/playground/video/hls/sintel-trailer.m3u8',
262
                          loc('kivy_test.py'): [u'https://walterebert.com/playground/video/hls/sintel-trailer.m3u8',
263
         u'https://dl4.sanii.co/files/2/60e13omc1cpph2/video.mp4'],
263
         u'https://dl4.sanii.co/files/2/60e13omc1cpph2/video.mp4'],
264
-                         loc('run.py'): [u'config::home  ftp://user:Kaskade7@home.blue.lv/hdd/streams.cfg',
264
+                         loc('run.py'): [u'config::home  ftp://user:xxxx@home.blue.lv/hdd/streams.cfg',
265
         u'config::home sources\\cfg0\\streams_al.cfg',
265
         u'config::home sources\\cfg0\\streams_al.cfg',
266
         u'config::home ',
266
         u'config::home ',
267
-        u'config::home  ftp://user:Kaskade7@home.blue.lv/hdd/streams_al.cfg',
268
-        u'config::home  ftps://user:Kaskade7@home.blue.lv/hdd/streams_al.cfg',
269
-        u'config::home  ftp://user:Kaskade7@home.blue.lv/hdd/streams_al.cfg2',
267
+        u'config::home  ftp://user:xxxx@home.blue.lv/hdd/streams_al.cfg',
268
+        u'config::home  ftps://user:xxxx@home.blue.lv/hdd/streams_al.cfg',
269
+        u'config::home  ftp://user:xxxx@home.blue.lv/hdd/streams_al.cfg2',
270
         u'config::home  ftp://home.blue.lv/hdd/streams_al.cfg',
270
         u'config::home  ftp://home.blue.lv/hdd/streams_al.cfg',
271
         u'config::home  ',
271
         u'config::home  ',
272
         u'config::home  streams_bernu.cfg',
272
         u'config::home  streams_bernu.cfg',

+ 1
- 2
sources/config.py View File

164
 
164
 
165
 if __name__ == "__main__":
165
 if __name__ == "__main__":
166
 
166
 
167
-    source = Source(cfg_file="ftp://user:Kaskade7@home.blue.lv/hdd/streams.cfg")
168
-    #source = Source(cfg_file="streams.cfg")
167
+    source = Source(cfg_file="streams.cfg")
169
     source.read_streams()
168
     source.read_streams()
170
     source.write_streams()
169
     source.write_streams()
171
     import sys
170
     import sys

+ 1
- 1
sources/viaplay.py View File

100
         url = "https://viaplay.lv/tdi/login/nav/form?csrfToken=%s"%self.csrfToken
100
         url = "https://viaplay.lv/tdi/login/nav/form?csrfToken=%s"%self.csrfToken
101
         #      https://viaplay.lv/tdi/login/nav/form?_infuse=1&_ts=1490554674901&csrfToken=
101
         #      https://viaplay.lv/tdi/login/nav/form?_infuse=1&_ts=1490554674901&csrfToken=
102
         params = "nav_redirectUri=https%3A%2F%2Fviaplay.lv%2F&nav_email={}&nav_password={}".format(urllib.quote(user),urllib.quote(password))
102
         params = "nav_redirectUri=https%3A%2F%2Fviaplay.lv%2F&nav_email={}&nav_password={}".format(urllib.quote(user),urllib.quote(password))
103
-        #         nav_redirectUri=https%3A%2F%2Fviaplay.lv%2F&nav_email=ivars777%40gmail.com&nav_password=kaskade7&nav_remember=true
103
+        #         nav_redirectUri=https%3A%2F%2Fviaplay.lv%2F&nav_email=ivars777%40gmail.com&nav_password=xxxx&nav_remember=true
104
         headers["Cookie"] = "ott_cookies_confirmed=1; PLAY_SESSION=%s;"%self.play_session
104
         headers["Cookie"] = "ott_cookies_confirmed=1; PLAY_SESSION=%s;"%self.play_session
105
         if self.device:
105
         if self.device:
106
             headers["Cookie"] += "ott_dids=%s"%self.device
106
             headers["Cookie"] += "ott_dids=%s"%self.device