Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(462)

Issue 2168303003: Removing 'AllowScopedIO' exception from SecurityKeyAuthHandlerLinux (Closed)

Created:
4 years, 5 months ago by joedow
Modified:
4 years, 5 months ago
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, extensions-reviews_chromium.org, chromoting-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@temp_dir
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Removing 'AllowScopedIO' exception from SecurityKeyAuthHandlerLinux This change updates the SecurityKeyAuthHandlerLinux class to run its socket operations on a task_runner which allows blocking IO. The first part of the change is plumbing through the file_task_runner from the Me2Me host (which owns the context with the task runners) down to the auth handler class which requires it. The second part of the change was to move the file delete operation to the file thread and then post back to the main thread. I've also updated the unit tests for the affected class since it now needs to handle synchronization between two threads. BUG=591739 R=sergeyu@chromium.org TBR=dpranke@chromium.org Committed: https://crrev.com/a6a4b6a1fd3a1dee72e8d03d460cd0c5f8d182d9 Cr-Commit-Position: refs/heads/master@{#407649}

Patch Set 1 #

Patch Set 2 : Addressing feedback #

Total comments: 6

Patch Set 3 : Addressing Feedback #

Patch Set 4 : Fixing some comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+133 lines, -68 lines) Patch
M PRESUBMIT.py View 1 chunk +0 lines, -2 lines 0 comments Download
M remoting/host/chromoting_host.cc View 1 chunk +1 line, -1 line 0 comments Download
M remoting/host/remoting_me2me_host.cc View 2 chunks +3 lines, -2 lines 0 comments Download
M remoting/host/security_key/security_key_auth_handler.h View 2 chunks +4 lines, -1 line 0 comments Download
M remoting/host/security_key/security_key_auth_handler_android.cc View 1 chunk +2 lines, -1 line 0 comments Download
M remoting/host/security_key/security_key_auth_handler_linux.cc View 1 2 3 8 chunks +46 lines, -28 lines 0 comments Download
M remoting/host/security_key/security_key_auth_handler_linux_unittest.cc View 1 9 chunks +40 lines, -21 lines 0 comments Download
M remoting/host/security_key/security_key_auth_handler_mac.cc View 1 chunk +2 lines, -1 line 0 comments Download
M remoting/host/security_key/security_key_auth_handler_win.cc View 1 chunk +2 lines, -1 line 0 comments Download
M remoting/host/security_key/security_key_auth_handler_win_unittest.cc View 1 chunk +2 lines, -1 line 0 comments Download
M remoting/host/security_key/security_key_extension.h View 3 chunks +10 lines, -1 line 0 comments Download
M remoting/host/security_key/security_key_extension.cc View 3 chunks +6 lines, -2 lines 0 comments Download
M remoting/host/security_key/security_key_extension_session.h View 2 chunks +7 lines, -3 lines 0 comments Download
M remoting/host/security_key/security_key_extension_session.cc View 2 chunks +5 lines, -2 lines 0 comments Download
M remoting/host/security_key/security_key_extension_session_unittest.cc View 1 chunk +3 lines, -1 line 0 comments Download

Messages

Total messages: 29 (15 generated)
joedow
PTAL! sergeyu@ for remoting changes. dpranke@ for presubmit.py change. Thanks, Joe
4 years, 5 months ago (2016-07-22 20:41:24 UTC) #5
Dirk Pranke
lgtm
4 years, 5 months ago (2016-07-22 21:17:57 UTC) #6
Sergey Ulanov
SecurityKeyAuthHandlerLinux currently doesn't require any blocking IO, except DeleteFile(). So I don't think it's necessary ...
4 years, 5 months ago (2016-07-22 21:25:02 UTC) #7
joedow
It's true that the AllowScopedIO exception was added for the DeleteFile call, but my thought ...
4 years, 5 months ago (2016-07-22 22:27:26 UTC) #8
joedow
Discussed with Sergey offline. Socket operations are light enough that moving them to another thread ...
4 years, 5 months ago (2016-07-23 00:16:44 UTC) #11
joedow
Ping!
4 years, 5 months ago (2016-07-25 15:52:31 UTC) #16
Sergey Ulanov
Thanks for fixing it! https://codereview.chromium.org/2168303003/diff/20001/remoting/host/security_key/security_key_auth_handler_linux.cc File remoting/host/security_key/security_key_auth_handler_linux.cc (right): https://codereview.chromium.org/2168303003/diff/20001/remoting/host/security_key/security_key_auth_handler_linux.cc#newcode164 remoting/host/security_key/security_key_auth_handler_linux.cc:164: file_task_runner_->PostTaskAndReply( add a comment to ...
4 years, 5 months ago (2016-07-25 18:29:55 UTC) #17
Sergey Ulanov
forgot lgtm (when my comments are addressed)
4 years, 5 months ago (2016-07-25 18:30:26 UTC) #18
joedow
Thanks! https://codereview.chromium.org/2168303003/diff/20001/remoting/host/security_key/security_key_auth_handler_linux.cc File remoting/host/security_key/security_key_auth_handler_linux.cc (right): https://codereview.chromium.org/2168303003/diff/20001/remoting/host/security_key/security_key_auth_handler_linux.cc#newcode164 remoting/host/security_key/security_key_auth_handler_linux.cc:164: file_task_runner_->PostTaskAndReply( On 2016/07/25 18:29:55, Sergey Ulanov wrote: > ...
4 years, 5 months ago (2016-07-25 22:39:25 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2168303003/60001
4 years, 5 months ago (2016-07-25 22:39:59 UTC) #22
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/268651)
4 years, 5 months ago (2016-07-25 23:56:39 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2168303003/60001
4 years, 5 months ago (2016-07-25 23:58:55 UTC) #26
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 5 months ago (2016-07-26 00:29:36 UTC) #27
commit-bot: I haz the power
4 years, 5 months ago (2016-07-26 00:32:40 UTC) #29
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/a6a4b6a1fd3a1dee72e8d03d460cd0c5f8d182d9
Cr-Commit-Position: refs/heads/master@{#407649}

Powered by Google App Engine
This is Rietveld 408576698