Skip to content

Commit 6241c5b

Browse files
committed
add method to get algorithm id from name
1 parent bbc5874 commit 6241c5b

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/Common/Microsoft/PasswordEncoder.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,17 @@ private static function getAlgorithm($algorithmName)
162162
return $algorithm;
163163
}
164164

165+
/**
166+
* Returns the algorithm ID
167+
*
168+
* @param sting $algorithmName
169+
* @return int
170+
*/
171+
public static function getAlgorithmId($algorithmName)
172+
{
173+
return self::$algorithmMapping[$algorithmName][0];
174+
}
175+
165176
/**
166177
* Build combined key from low-order word and high-order word
167178
*

0 commit comments

Comments
 (0)