diff --git a/pharo-porting/changes_for_pharo.st b/pharo-porting/changes_for_pharo.st index 9de32d1..99fbdc0 100644 --- a/pharo-porting/changes_for_pharo.st +++ b/pharo-porting/changes_for_pharo.st @@ -2,17 +2,17 @@ SIPURandom class extend [ nextByte [ - ^(RAND rand: 1) first. + ^(OsmoSecureRandom rand: 1) first. ] nextInt [ - ^(RAND rand: 4) asInteger + ^(OsmoSecureRandom rand: 4) asInteger ] nextFourBytes [ - ^RAND rand: 4 + ^OsmoSecureRandom rand: 4 ] ] @@ -20,14 +20,14 @@ SIPUserAgentBase class extend [ generateCSeq [ "For pharo just use the random we have" - ^(RAND rand: 4) asInteger abs + ^(OsmoSecureRandom rand: 4) asInteger abs ] generateBranch [ | data | data := '<1p>,<2p>' expandMacrosWithArguments: {DateTime now asUTC asSeconds. - (RAND rand: 2) asInteger}. + (OsmoSecureRandom rand: 2) asInteger}. ^ self branchStart, (SIPBase64 encode: data). ] ]