|
READ ONLY FORUM: m23 :: makes software distribution easy The m23 discussion forum
|
View previous topic :: View next topic |
Author |
Message |
TheGuv
Joined: 29 Oct 2010 Posts: 11
|
Posted: Wed Nov 17, 2010 9:20 Post subject: ASSI_addClient does not define password var |
|
|
I discovered that function ASSI_addClient (in assimilate.php) does not define $data['password'] which is defined in CLIENT_addClient (client.php) as being populated.
The following patch will correct this on 10.5:
Code: |
--- assimilate.php.bak 2010-11-09 10:56:53.000000000 +0000
+++ assimilate.php 2010-11-17 10:32:48.000000000 +0000
@@ -56,6 +56,7 @@
$data['client'] = $client;
$data['ip'] = $ip;
$data['newgroup'] = "default";
+ $data['rootpassword'] = $password;
$err = CLIENT_addClient($data,"",CLIENT_ADD_TYPE_assimilate,false);
|
EDIT: fixup to use the correct key for $data.
--
TheGuv
Last edited by TheGuv on Wed Nov 17, 2010 13:20; edited 2 times in total |
|
Back to top |
|
|
Hauke
Joined: 02 Mar 2003 Posts: 1072
|
Posted: Wed Nov 17, 2010 11:32 Post subject: |
|
|
Hi,
I would be surprised, if it works, because "password" is no key of the $data array.
Did you try it?
But
Code: | $data['rootpassword'] = $password; |
should do it.
Can you try this and check? _________________ Hauke Goos-Habermann
- project leader m23 (http://m23.sf.net) -
Jabber: dodgerm23@jabber.org
Schulung, Entwicklung und Support zu m23 und anderen OpenSource-Produkten: www.goos-habermann.de
Auch DU kannst etwas gegen Softwarepatente tun! www.patentfrei.de |
|
Back to top |
|
|
TheGuv
Joined: 29 Oct 2010 Posts: 11
|
Posted: Wed Nov 17, 2010 13:17 Post subject: |
|
|
Hauke wrote: | Hi,
I would be surprised, if it works, because "password" is no key of the $data array.
Did you try it?
|
Yes I tried it and it works, but for the wrong reason!
In my other patch (whcih is what this one was to support) I added function CLIENT_addSvrEtcHosts() like this:
CLIENT_addSvrEtcHosts($data['ip'], $data['password'], $_SERVER[SERVER_NAME],
Of course it would work, as both patches use $data['password'] instead of $data['rootpassword']
I'll fix that up - thanks for spotting. |
|
Back to top |
|
|
|
|
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|