Skip to content

Commit dc6aa0d

Browse files
committed
Force Steam auth id to secure always
* This was "our bug" and probably should have been anticipated back in the begginning of OUJS with Steam * This takes care of the wishy-washy replies I read on a possible reversion from secure to unsecure in their routines. We never utilize the plain text value stored in `aId` so it's not important to match site secure status NOTE(S): * There is a manual recovery path discovered for those who have access to the DB directly but working on offloading it to the users. Need sleep first then more testing. * Still keeping steam auth read-only until the DB can be examined further and this issue recovery Applies to OpenUserJS#1347
1 parent e712f12 commit dc6aa0d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

libs/passportVerify.js

+5
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ exports.verify = function (aId, aStrategy, aUsername, aLoggedIn, aDone) {
3232
} else if (aStrategy === 'github') {
3333
// We only keep plaintext ids for GH since that's all we need
3434
digest = aId;
35+
} else if (aStrategy === 'steam') {
36+
// Having these forced secure ids would allow us to do things with the user's
37+
// account and that is something we DO NOT want to do
38+
shasum.update(String(aId).replace(/^http:/, 'https:'));
39+
digest = shasum.digest('hex');
3540
} else {
3641
// Having these ids would allow us to do things with the user's
3742
// account and that is something we DO NOT want to do

0 commit comments

Comments
 (0)