phanterpwa 14.0.6__py3-none-any.whl → 14.0.7__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- phanterpwa/__init__.py +1 -1
- phanterpwa/backend/pydal/credentials.py +4 -4
- phanterpwa/backend/request_handlers/credentials.py +14 -11
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/METADATA +1 -1
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/RECORD +10 -10
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/LICENSE +0 -0
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/WHEEL +0 -0
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/dependency_links.txt +0 -0
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/entry_points.txt +0 -0
- {phanterpwa-14.0.6.dist-info → phanterpwa-14.0.7.dist-info}/top_level.txt +0 -0
phanterpwa/__init__.py
CHANGED
@@ -15,7 +15,7 @@ class CredentialsTables():
|
|
15
15
|
Field('token', 'text', index=True),
|
16
16
|
Field('auth_user', 'reference auth_user', requires=IS_EMPTY_OR(
|
17
17
|
IS_IN_DB(self.DALDatabase, self.DALDatabase.auth_user))),
|
18
|
-
Field('date_created', 'datetime', default=datetime.now(), requires=IS_EMPTY_OR(IS_DATETIME())),
|
18
|
+
Field('date_created', 'datetime', index=True, default=datetime.now(), requires=IS_EMPTY_OR(IS_DATETIME())),
|
19
19
|
Field('last_resign', 'datetime', default=datetime.now()),
|
20
20
|
Field('remember_me', 'boolean', default=False),
|
21
21
|
Field('locked', 'boolean', default=False),
|
@@ -26,7 +26,7 @@ class CredentialsTables():
|
|
26
26
|
Field('form_identify', 'string'),
|
27
27
|
Field('user_agent', 'string'),
|
28
28
|
Field('ip', 'string'),
|
29
|
-
Field('date_created', 'datetime', default=datetime.now(), requires=IS_DATETIME()),
|
29
|
+
Field('date_created', 'datetime', index=True, default=datetime.now(), requires=IS_DATETIME()),
|
30
30
|
Field('client', 'reference client', requires=IS_EMPTY_OR(
|
31
31
|
IS_IN_DB(self.DALDatabase, self.DALDatabase.client)))
|
32
32
|
)
|
@@ -36,7 +36,7 @@ class CredentialsTables():
|
|
36
36
|
Field('form_identify', 'string'),
|
37
37
|
Field('user_agent', 'string'),
|
38
38
|
Field('ip', 'string'),
|
39
|
-
Field('date_created', 'datetime', default=datetime.now(), requires=IS_DATETIME()),
|
39
|
+
Field('date_created', 'datetime', index=True, default=datetime.now(), requires=IS_DATETIME()),
|
40
40
|
Field('client', 'reference client', requires=IS_EMPTY_OR(
|
41
41
|
IS_IN_DB(self.DALDatabase, self.DALDatabase.client)))
|
42
42
|
)
|
@@ -46,7 +46,7 @@ class CredentialsTables():
|
|
46
46
|
Field('form_identify', 'string'),
|
47
47
|
Field('user_agent', 'string'),
|
48
48
|
Field('ip', 'string'),
|
49
|
-
Field('date_created', 'datetime', default=datetime.now(), requires=IS_DATETIME()),
|
49
|
+
Field('date_created', 'datetime', index=True, default=datetime.now(), requires=IS_DATETIME()),
|
50
50
|
Field('client', 'reference client', requires=IS_EMPTY_OR(
|
51
51
|
IS_IN_DB(self.DALDatabase, self.DALDatabase.client)))
|
52
52
|
)
|
@@ -98,17 +98,20 @@ class SignClient(web.RequestHandler):
|
|
98
98
|
deactived_user_expire_date = datetime.now() - timedelta(seconds=self.projectConfig['BACKEND'][self.app_name]['default_time_user_token_expire_remember_me'])
|
99
99
|
str_expire_date = expire_date.strftime('%Y-%m-%d %H:%M:%S')
|
100
100
|
str_anonymous_expire_date = anonymous_expire_date.strftime('%Y-%m-%d %H:%M:%S')
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
101
|
+
global CLEANUP_TIME
|
102
|
+
if CLEANUP_TIME < datetime.now() - timedelta(seconds=600):
|
103
|
+
CLEANUP_TIME = datetime.now()
|
104
|
+
self.DALDatabase(
|
105
|
+
(self.DALDatabase.client.date_created < str_expire_date)
|
106
|
+
).delete()
|
107
|
+
self.DALDatabase(
|
108
|
+
(self.DALDatabase.client.auth_user == None)
|
109
|
+
& (self.DALDatabase.client.date_created < str_anonymous_expire_date)
|
110
|
+
).delete()
|
111
|
+
self.DALDatabase(
|
112
|
+
(self.DALDatabase.auth_user.activated == False)
|
113
|
+
& ((self.DALDatabase.auth_user.date_created < deactived_user_expire_date) | (self.DALDatabase.auth_user.date_created == None))
|
114
|
+
).delete()
|
112
115
|
|
113
116
|
self.phanterpwa_client_token = self.request.headers.get('phanterpwa-client-token')
|
114
117
|
self.phanterpwa_authorization = self.request.headers.get('phanterpwa-authorization')
|
@@ -1,4 +1,4 @@
|
|
1
|
-
phanterpwa/__init__.py,sha256=
|
1
|
+
phanterpwa/__init__.py,sha256=puoz8HlNiXwRfWbmPd0IKWKxHEqE0lxhm0pRSnbctPM,396
|
2
2
|
phanterpwa/__main__.py,sha256=1vSHtv6-sgAgpZiklf9bwarXX1b-fmKx1rjwJw4h78o,4017
|
3
3
|
phanterpwa/compiler.py,sha256=Je3qtVO_cZ69_PPWcXKyBgnRfQ-Ev-zkZ3UTN-ddOTQ,47478
|
4
4
|
phanterpwa/configer.py,sha256=PFO_nVy9r6yt5iDso1amDIR0Ge2UYYK3h-ae9M0Ezyk,26359
|
@@ -16,7 +16,7 @@ phanterpwa/backend/security.py,sha256=USPky7nqTKASAN60yYs7-NnoR82LMZlf9aGlfz1QbX
|
|
16
16
|
phanterpwa/backend/pydal/__init__.py,sha256=lpPDHcS9anJ5ceRSW9fBVuAgKK5qtjSoMsVjp3_nCdw,55
|
17
17
|
phanterpwa/backend/pydal/auth.py,sha256=fvRI4vyjjl0ZBuCGjcinp4mVd8sU4Wd1skLoHX_ter8,8606
|
18
18
|
phanterpwa/backend/pydal/cas.py,sha256=PJvHZdXu4JQM0BAEkYSMTw-_Zc8zrlXR200GTA869kg,1581
|
19
|
-
phanterpwa/backend/pydal/credentials.py,sha256=
|
19
|
+
phanterpwa/backend/pydal/credentials.py,sha256=b3qeobNmm7pGB7hmbAYpxq2BT222UZ2wpcuDOJ3VXpE,2331
|
20
20
|
phanterpwa/backend/pydal/extra_validations.py,sha256=1FlOZhUuYg4aybL4EwSzH3zWUXbGtOwxxfVxK-qjHkM,1919
|
21
21
|
phanterpwa/backend/pydal/gallery.py,sha256=nETfQ2Dv-0N94Ypq14uGiDKeGlWgxDHLjY4s1zFrnWs,870
|
22
22
|
phanterpwa/backend/pydal/internal_messages.py,sha256=DYDNWpjrvAM0Nn4m5fGkJXJsMVQjwuJgcMaRzOEzmE4,1379
|
@@ -24,7 +24,7 @@ phanterpwa/backend/request_handlers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQ
|
|
24
24
|
phanterpwa/backend/request_handlers/admin.py,sha256=QnpoCTMRBuviSCdB84G0pUb13kIg6ky8Wv4DEVB7tRQ,63978
|
25
25
|
phanterpwa/backend/request_handlers/auth.py,sha256=epJ2ura3u6YDKNRmvyYGR7FzF1nrgwTpneibP0z9zzw,177284
|
26
26
|
phanterpwa/backend/request_handlers/cas.py,sha256=TeeQaodcHVkhu-cUqesh9NeAuo0oXylzcPXpQ9wG6H4,24996
|
27
|
-
phanterpwa/backend/request_handlers/credentials.py,sha256=
|
27
|
+
phanterpwa/backend/request_handlers/credentials.py,sha256=Gs6Rje80A8PaPqYpB39dMlikcXewp9pOLFR9JROH-mU,51550
|
28
28
|
phanterpwa/backend/request_handlers/errors.py,sha256=x3SMdpkO4mxaSRZZQQxtH1zUFh47C06kssfI4CoPokc,4472
|
29
29
|
phanterpwa/backend/request_handlers/i18n_server.py,sha256=p3LQxOdcLHIjgaFs4wO1V2_7gKpfcDT7pDPa7m0-UbQ,3205
|
30
30
|
phanterpwa/backend/request_handlers/internal_messages.py,sha256=w_u3NYw0KZfuCIS8tHJhV12tj_UA0_aBekk22nR3oCc,17382
|
@@ -435,10 +435,10 @@ phanterpwa/usual_sass/preloaders/indefined_text.sass,sha256=z4JuUtBrzoqH3HuNFXvN
|
|
435
435
|
phanterpwa/usual_sass/preloaders/run_points.sass,sha256=EYl93ljfgAc-ZLJ0VScrCoIlHP7Nr6NLdxj1zk2wm_E,3367
|
436
436
|
phanterpwa/usual_sass/preloaders/square.sass,sha256=TOsh9muP4zkYLUJcw4i1LeRs60NrtgRWBk_1oMt2_58,1348
|
437
437
|
phanterpwa/usual_sass/preloaders/squares.sass,sha256=kH1I89qEfmbvYxCtKFVNcxP5bWIjnqbheXVnyGF0VNo,3862
|
438
|
-
phanterpwa-14.0.
|
439
|
-
phanterpwa-14.0.
|
440
|
-
phanterpwa-14.0.
|
441
|
-
phanterpwa-14.0.
|
442
|
-
phanterpwa-14.0.
|
443
|
-
phanterpwa-14.0.
|
444
|
-
phanterpwa-14.0.
|
438
|
+
phanterpwa-14.0.7.dist-info/LICENSE,sha256=lGEW1PRSZOkug2-d0IJgryCjqt6zhxN5x9pFgy3lx2E,1087
|
439
|
+
phanterpwa-14.0.7.dist-info/METADATA,sha256=E6YAHYwaPI2_EHAUXVpkVdjt2ERmHg389CJmmzl8xy8,1938
|
440
|
+
phanterpwa-14.0.7.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
|
441
|
+
phanterpwa-14.0.7.dist-info/dependency_links.txt,sha256=Pslekmz-4l1SpBO0x2aYkYZPCScmbrB9HUq1YvXYUzM,40
|
442
|
+
phanterpwa-14.0.7.dist-info/entry_points.txt,sha256=siJH2lFXIdsUBDRgcXV4blOb2_iku1vcbqxJ-trIQrw,56
|
443
|
+
phanterpwa-14.0.7.dist-info/top_level.txt,sha256=nF1WJ8AByxBv3bLKp3xySR2l2Twrj5n5n7C404lULSk,5319
|
444
|
+
phanterpwa-14.0.7.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|