[prev in list] [next in list] [prev in thread] [next in thread]
List: lon-capa-cvs
Subject: [LON-CAPA-cvs] cvs: loncom /lti ltiutils.pm
From: raeburn <raeburn () source ! lon-capa ! org>
Date: 2018-05-15 4:33:18
Message-ID: cvsraeburn1526358798 () cvsserver
[Download RAW message or body]
raeburn Tue May 15 04:33:18 2018 EDT
Modified files:
/loncom/lti ltiutils.pm
Log:
- Seed rand before generating nonce.
Index: loncom/lti/ltiutils.pm
diff -u loncom/lti/ltiutils.pm:1.8 loncom/lti/ltiutils.pm:1.9
--- loncom/lti/ltiutils.pm:1.8 Tue Apr 17 14:03:01 2018
+++ loncom/lti/ltiutils.pm Tue May 15 04:33:17 2018
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Utility functions for managing LON-CAPA LTI interactions
#
-# $Id: ltiutils.pm,v 1.8 2018/04/17 14:03:01 raeburn Exp $
+# $Id: ltiutils.pm,v 1.9 2018/05/15 04:33:17 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -324,6 +324,7 @@
if ($sigmethod eq '') {
$sigmethod = 'HMAC-SHA1';
}
+ srand( time() ^ ($$ + ($$ << 15)) ); # Seed rand.
my $nonce = Digest::SHA::sha1_hex(sprintf("%06x%06x",rand(0xfffff0),rand(0xfffff0)));
my $request = Net::OAuth->request("request token")->new(
consumer_key => $key,
_______________________________________________
LON-CAPA-cvs mailing list
LON-CAPA-cvs@mail.lon-capa.org
http://mail.lon-capa.org/mailman/listinfo/lon-capa-cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic