Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
SiCKRAGE
sickrage
Commits
758a5956
Commit
758a5956
authored
Aug 27, 2021
by
echel0n
Browse files
Merge branch 'release/10.0.34'
parents
1ea1fd89
12fa227d
Changes
12
Expand all
Hide whitespace changes
Inline
Side-by-side
CHANGELOG.md
View file @
758a5956
...
...
@@ -2,8 +2,12 @@
All notable changes to this project will be documented in this file. Dates are displayed in UTC.
#### [10.0.34](https://git.sickrage.ca/SiCKRAGE/sickrage/compare/10.0.33...10.0.34)
#### [10.0.33](https://git.sickrage.ca/SiCKRAGE/sickrage/compare/10.0.32...10.0.33)
> 24 August 2021
#### [10.0.32](https://git.sickrage.ca/SiCKRAGE/sickrage/compare/10.0.31...10.0.32)
> 10 August 2021
...
...
package.json
View file @
758a5956
{
"name"
:
"sickrage"
,
"version"
:
"10.0.3
3
"
,
"version"
:
"10.0.3
4
"
,
"private"
:
true
,
"repository"
:
{
"type"
:
"git"
,
...
...
setup.cfg
View file @
758a5956
[bumpversion]
current_version = 10.0.3
3
current_version = 10.0.3
4
commit = False
tag = False
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(\.(?P<release>[a-z]+)(?P<dev>\d+))?
...
...
sickrage/__init__.py
View file @
758a5956
...
...
@@ -19,7 +19,7 @@
# along with SiCKRAGE. If not, see <http://www.gnu.org/licenses/>.
# ##############################################################################
__version__
=
"10.0.3
3
"
__version__
=
"10.0.3
4
"
__install_type__
=
""
import
argparse
...
...
sickrage/checksums.md5
View file @
758a5956
This diff is collapsed.
Click to expand it.
sickrage/core/api/__init__.py
View file @
758a5956
...
...
@@ -115,6 +115,9 @@ class API(object):
def
token_expiration
(
self
):
try
:
certs
=
sickrage
.
app
.
auth_server
.
certs
()
if
not
certs
:
return
time
.
time
()
decoded_token
=
sickrage
.
app
.
auth_server
.
decode_token
(
self
.
token
[
'access_token'
],
certs
)
return
decoded_token
.
get
(
'exp'
,
time
.
time
())
except
ExpiredSignatureError
:
...
...
sickrage/core/auth/__init__.py
View file @
758a5956
...
...
@@ -21,6 +21,7 @@
import
requests
from
keycloak.exceptions
import
KeycloakClientError
from
keycloak.openid_connect
import
KeycloakOpenidConnect
from
keycloak.realm
import
KeycloakRealm
...
...
@@ -62,7 +63,7 @@ class AuthServer(object):
def
get_url
(
self
,
*
args
,
**
kwargs
):
try
:
return
self
.
client
.
get_url
(
*
args
,
**
kwargs
)
except
requests
.
exceptions
.
ConnectionError
as
e
:
except
(
KeycloakClientError
,
requests
.
exceptions
.
ConnectionError
)
as
e
:
return
def
certs
(
self
):
...
...
sickrage/core/webserver/handlers/api/__init__.py
View file @
758a5956
...
...
@@ -53,6 +53,9 @@ class APIBaseHandler(RequestHandler):
return
certs
=
sickrage
.
app
.
auth_server
.
certs
()
if
not
certs
:
return
auth_header
=
self
.
request
.
headers
.
get
(
'Authorization'
)
if
auth_header
:
...
...
@@ -134,6 +137,9 @@ class APIBaseHandler(RequestHandler):
auth_header
=
self
.
request
.
headers
.
get
(
'Authorization'
)
if
'bearer'
in
auth_header
.
lower
():
certs
=
sickrage
.
app
.
auth_server
.
certs
()
if
not
certs
:
return
token
=
auth_header
.
strip
(
'Bearer'
).
strip
()
decoded_token
=
sickrage
.
app
.
auth_server
.
decode_token
(
token
,
certs
)
if
sickrage
.
app
.
config
.
user
.
sub_id
==
decoded_token
.
get
(
'sub'
):
...
...
sickrage/core/webserver/handlers/login.py
View file @
758a5956
...
...
@@ -52,6 +52,10 @@ class LoginHandler(BaseHandler):
def
handle_jwt_auth_get
(
self
):
certs
=
sickrage
.
app
.
auth_server
.
certs
()
if
not
certs
:
self
.
set_status
(
401
)
return
{
'error'
:
'Unable to verify token'
}
auth_token
=
self
.
request
.
headers
[
'Authorization'
].
strip
(
'Bearer'
).
strip
()
try
:
...
...
sickrage/core/webserver/static/js/core.min.js
View file @
758a5956
This diff is collapsed.
Click to expand it.
sickrage/core/websocket/__init__.py
View file @
758a5956
...
...
@@ -32,6 +32,10 @@ class WebSocketUIHandler(WebSocketHandler):
json_message
=
json
.
loads
(
message
)
if
json_message
.
get
(
'initial'
,
False
):
certs
=
sickrage
.
app
.
auth_server
.
certs
()
if
not
certs
:
WebSocketUIHandler
.
clients
.
remove
(
self
)
return
self
.
close
(
401
,
'Unable to verify token'
)
auth_token
=
json_message
[
'token'
]
try
:
...
...
sickrage/version.txt
View file @
758a5956
10.0.33
\ No newline at end of file
10.0.34
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment