Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
coco
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
coco
Commits
3be4f102
Unverified
Commit
3be4f102
authored
May 24, 2018
by
老广
Committed by
GitHub
May 24, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #59 from jumpserver/dev
Dev
parents
40ac8f51
e4da494d
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
7 deletions
+4
-7
app.py
coco/app.py
+1
-1
httpd.py
coco/httpd.py
+1
-4
logger.py
coco/logger.py
+2
-2
No files found.
coco/app.py
View file @
3be4f102
...
...
@@ -25,7 +25,7 @@ from .utils import get_logger, register_app, register_service
eventlet
.
monkey_patch
()
hub_prevent_multiple_readers
(
False
)
__version__
=
'1.3.
0
'
__version__
=
'1.3.
1
'
BASE_DIR
=
os
.
path
.
dirname
(
os
.
path
.
dirname
(
__file__
))
logger
=
get_logger
(
__file__
)
...
...
coco/httpd.py
View file @
3be4f102
...
...
@@ -167,13 +167,11 @@ class ProxyNamespace(BaseNamespace):
secret
=
message
.
get
(
'secret'
,
None
)
room
=
self
.
new_room
()
self
.
emit
(
'room'
,
{
'room'
:
room
[
"id"
],
'secret'
:
secret
})
self
.
socketio
.
sleep
(
0
)
if
not
token
or
not
secret
:
logger
.
debug
(
"Token or secret is None
"
)
logger
.
debug
(
"Token or secret is None
: {}"
.
format
(
token
,
secret
)
)
self
.
emit
(
'data'
,
{
'data'
:
"
\n
Operation not permitted!"
,
'room'
:
room
[
"id"
]})
self
.
emit
(
'disconnect'
)
self
.
socketio
.
sleep
(
0
)
return
None
info
=
app_service
.
get_token_asset
(
token
)
...
...
@@ -183,7 +181,6 @@ class ProxyNamespace(BaseNamespace):
self
.
emit
(
'data'
,
{
'data'
:
"
\n
Operation not permitted!"
,
'room'
:
room
[
"id"
]})
self
.
emit
(
'disconnect'
)
self
.
socketio
.
sleep
(
0
)
return
None
user_id
=
info
.
get
(
'user'
,
None
)
...
...
coco/logger.py
View file @
3be4f102
...
...
@@ -49,8 +49,8 @@ def create_logger(app):
'coco'
:
main_setting
,
'paramiko'
:
main_setting
,
'jms'
:
main_setting
,
'socket.io'
:
main_setting
,
'engineio'
:
main_setting
,
#
'socket.io': main_setting,
#
'engineio': main_setting,
}
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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