about summary refs log tree commit diff stats
path: root/update/library/trunk
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2008-09-20 00:36:06 +0000
committerKelly Rauchenberger <fefferburbia@gmail.com>2008-09-20 00:36:06 +0000
commitdc0193b43d85718d108762ad72a620c79f1a0b4c (patch)
treec9e62d6e999fc6a17cd2fbc1583756ec6b88ffa7 /update/library/trunk
parent22273ef627cc8f9be11edb6b0207fa0ec35c267f (diff)
downloadinstadisc-dc0193b43d85718d108762ad72a620c79f1a0b4c.tar.gz
instadisc-dc0193b43d85718d108762ad72a620c79f1a0b4c.tar.bz2
instadisc-dc0193b43d85718d108762ad72a620c79f1a0b4c.zip
Update: Added back password capability
Refs #61 and #10
Diffstat (limited to 'update/library/trunk')
-rw-r--r--update/library/trunk/instadisc.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/update/library/trunk/instadisc.php b/update/library/trunk/instadisc.php index c0af8fa..975481c 100644 --- a/update/library/trunk/instadisc.php +++ b/update/library/trunk/instadisc.php
@@ -4,18 +4,18 @@
4 4
5include('xmlrpc/xmlrpc.inc'); 5include('xmlrpc/xmlrpc.inc');
6 6
7function instaDisc_sendItem($subTitle, $subCategory, $title, $author, $url, $semantics) 7function instaDisc_sendItem($title, $author, $url, $semantics, $subTitle, $subCategory, $subPassword = '')
8{ 8{
9 $subscriptionURL = 'http://'' . $_SERVER['SERVER_NAME'] . '/' . $subCategory . '/' . generateSlug($subTitle) . '/'; 9 $subscriptionURL = 'http://'' . $_SERVER['SERVER_NAME'] . '/' . $subCategory . '/' . generateSlug($subTitle) . '/';
10 10
11 $encID = 0; 11 $encID = 0;
12 if (($idusEncryptionKey[$id] != '') && extension_loaded('mcrypt')) 12 if (($subPassword != '') && extension_loaded('mcrypt'))
13 { 13 {
14 $encID = rand(1,2147483647); 14 $encID = rand(1,2147483647);
15 15
16 $cipher = "rijndael-128"; 16 $cipher = "rijndael-128";
17 $mode = "cbc"; 17 $mode = "cbc";
18 $key = substr(md5(substr(str_pad($idusEncryptionKey[$id],16,$encID),0,16)),0,16); 18 $key = substr(md5(substr(str_pad($subPassword[$id],16,$encID),0,16)),0,16);
19 19
20 $td = mcrypt_module_open($cipher, "", $mode, ""); 20 $td = mcrypt_module_open($cipher, "", $mode, "");
21 21