Extension talk:HNP

Problem
Recently I setup mediawiki 1.13.2 in our company and want to use HNP to control the permissions of namespaces. However I meet a problem with HNP and I don’t know how to solve this problem. Could anybody please kindly give me some suggestion? Thanks!

I have installed StubManager V1.3.0, HNP V1.1.2 and ExtensionManager V2.0.1. I add 2 extra namespaces “IDTV_SW_EXT”, “IDTV_SW_INT” and their talk namespaces. I also add 2 extra groups “idtv_sw” and “idtv_eng”. “idtv_sw” is designed to access both namespaces. “idtv_eng” is designed to not access “IDTV_SW_INT”. But after I setup the group permission in MediaWiki:Registry/HNP. All users in “idtv_sw” and “idtv_eng” can’t access “IDTV_SW_EXT” and “IDTV_SW_INT”. The error message says

“The action you have requested is limited to users in one of the groups *, Users, idtv_sw, idtv_eng.” But the user is in “idtv_sw” or “idtv_eng”.

The following lines are already added in MediaWiki:Registry/HNP.

In my LocalSettings.php, I also add

require_once( "extensions/StubManager/StubManager.php" ); require_once( "$IP/extensions/HNP/HNP.php" );

Does anybody can help me? Thanks a lotJulesshen 01:50, 25 November 2008 (UTC)

Presentation
Sorry, but this extension gets 0/10 for user-friendliness, I'm afraid. Firstly, as there was next to no explanation of how it works, I stared at the template for long enough to think that I understood what I needed to do, but an example would be helpful. Having then decided that it was worth trying (as a replacement for NamespacePermissions), I found that I had to download the individual files from SVN, rather than just retrieve a tar.gz from ExtensionDistributor. Attention to these two areas would be much appreciated! ;-)

On a less critical note, "Namespace [In]dependant" should be "Namespace-[in]dependent" - -ant is the noun and -ent the adjective.

/Sam

Problems

 * 192.165.213.18 10:07, 27 August 2008 (UTC) Maybe I'm being thick, but it looks as if the section below has been shuffled. I presume that "Nope. Then again, to reap the full benefits of this extension, patches must be applied to the codebase anyways... and that's something I haven't done, nor do I have plans for this. Jean-Lou Dupont 15:24, 7 May 2008 (UTC)'" applies to Filburt's question re 1.12.0 and that Robert's contribution is offered as evidence. However, even so,I'm confused - what patches "must be applied to the codebase"? It looks as if you're saying that the extension won't work unless you apply the patches, but you're not saying what they are...?

/Sam

Hi, that's me once more,

I wanted to ask, if you have any expierences with the HNP extension under Mediawiki 1.12 yet? I tried it and it seems that the extension is ignored by MediaWiki 1.12. Am I right?

Thanks + Greetings, Filburt


 * I installed the HNP under MediaWiki 1.12, but could not protect a namespace from being read by anonymous users. After some tries I found the following patch in another Extension, and now everything seems to work fine for me. Regards, Robert.

function userCanRead(...) in include/Title.php: ... // PATCH begin ...


 * Nope. Then again, to reap the full benefits of this extension, patches must be applied to the codebase anyways... and that's something I haven't done, nor do I have plans for this. Jean-Lou Dupont 15:24, 7 May 2008 (UTC)

Hi again,

I went on trying various things. I think I got it. If you only define

instead of

than everything works proper. The first line is not necessary and does not work in this case.

Greetings, Filburt

Hi again,

I only wanted to show what is working and what is not working. It is possible to make all Main-Pages visible and than to hide one of them, but not to hide all pages and then make one of them visible. The following still hides every page in Main, including 'Laender'. I already tried various things but without any success :-(

Thank you! Filburt

Thank you for your answer. I changed the LocalSettings.php as you mentioned. Unfortunately it hasn’t solved the problem yet. It works in this way:

But it doesn’t help because new added pages should be invisible for anonymous.
 * does not hide new pages for anons: you need to put !read at least for blocking the read right. Jean-Lou Dupont 09:38, 21 April 2008 (UTC)

The problem with the error message in Language.php seems to be only with anonymous and user, but not with sysop rights – if I logged in there is no message.

Thanks ones more! Filburt

Hi,

I use your BizzWiki extension since month and it works proper – thank you ones more for this extension.

Now I updated to the newer version, that I can define the userrights on a MediaWiki-page. There were no bigger problems with the update but two problems I haven’t been able to solve yet:

1. In the old BizzwikiSettings.php I defined that all pages in NS_Main are invisible for anonymous except some pages I named. Now I tried to define the same rights in Mediawiki:Registry/HNP in this way:

Unfortunately it does not work. Anonymous are not allowed to read the named pages.
 * Sometimes, the main namespace is not configured with a "canonical name". In this case, add:

$wgCanonicalNamespaceNames[NS_MAIN] = "Main"; in LocalSettings.php. Jean-Lou Dupont 23:53, 20 April 2008 (UTC)

2. Since I’ve updated sometimes I get the following error-message:

Warning: array_slice [function.array-slice]: The first argument should be an array in C:\xampp\htdocs\lektoren\languages\Language.php on line 1153

There seems to be no problems except the message, but do you have any idea from where does it come from? I already updated the language.php – with no success.
 * I am not sure where this comes from. I would need more info to trouble shoot. Jean-Lou Dupont 23:53, 20 April 2008 (UTC)

Thanks a lot for your help + greetings

Filburt

I installed HNP with the page MediaWiki:Registry/HNP of your proposal, but I can't see any success. All the pages are viewable and it's not possible to hide Recent changes out of "Special pages".

Which extensions of your hand I have to install? ViewsourceRight, RegistryManager, GroupManager? Is it necessary to install BizzWiki?

A lot of questions and no solution?

Thank's. --A.Burgermeister 15:02, 16 November 2007 (UTC)
 * For limiting 'browsing' capability of a namespace (e.g. list in Special:Recentchanges), you must install Extension:BizzWiki.
 * Jean-Lou Dupont 16:03, 16 November 2007 (UTC)
 * I installed BizzWiki, but still as a anonymous user I can see Recentchanges. What shall I do? --A.Burgermeister 17:55, 16 November 2007 (UTC)
 * In German the Special pages are named Spezial. --A.Burgermeister 18:21, 16 November 2007 (UTC)
 * You must configure your HNP registry: the 'browse' right is per-namespace in scope. So, if you want to stop '*' from browsing the 'NS_TEMPLATE' (example), then.
 * Jean-Lou Dupont 18:41, 16 November 2007 (UTC)
 * from your example: and my idea of this line: no browsing, no reading, and so on. But the anonymous user can see all Specialpages! --A.Burgermeister 21:24, 16 November 2007 (UTC)
 * Of course, you set the page prefix to  thereby restricting access to the page descendants of Log. If you want to bar any * user from seeing any page in the NS_SPECIAL namespace, then do  .Jean-Lou Dupont 21:34, 16 November 2007 (UTC)

Adding users to a group
Maybe it is a simple question - however: How do I need to connect new users I added in MediaWiki with a new added usergroup in the hierarchy in the HNP-Editor?

Example:

Hierarchy:

--> How do I add Mr. Anybody to the elearner-group

Thank's a lot!!!

DKU, 9.11.2007
 * To add users to a particular group, you use a sysop account to access the page Special:Userrights. Jean-Lou Dupont 12:17, 9 November 2007 (UTC)

Yeah, that's clear. But the problem is that the groups are shown in Special:userrights are not the same ones like in the HNP-hierarchy-definition. On Special:userrights are still the standard usergroups Sysop, Beaurocrat and Bots...

I guess I forgot a definition somewhere? Thanks for your fast answer!

DKU, 9.11.2007
 * Use Extension:GroupManager
 * Jean-Lou Dupont 15:42, 9 November 2007 (UTC)

Hm, I installed GroupManager-Extension and defined in MediaWiki:Registry/Groups:

{| border = 1 {|

But unfortunately no changes in Special:userrights :-(

(Could it be a problem with the German MediaWiki-Version I use?)

DKU, 10.11.2007
 * I must admit I do not use Extension:GroupManager on a regular basis; based on your query, I have found some limitations with this extension... I must attend to those limitations at some point. Sorry for the inconveniences. Jean-Lou Dupont 12:19, 10 November 2007 (UTC)

I've managed to get HNP up and running on my 1.11 MW install. I've worked my way through a number of issues and have most everything working, but I am unable to move pages with any accounts. Sysop, normal, etc; they all give the same error

"You do not have permission to move pages on this wiki."

And I see this at the top of the page: HNP: action "move" namespace dependent but called from NS_SPECIAL.

I've assigned the "move" permission to everyone on the main namespace and the custom namespaces I've created, but it doesn't appear to be working. The error message isn't the normal HNP denied message though, which makes me think I'm hitting some sort of internal mediawiki block. I was able to move pages before I set up HNP, so something must be different.

Any ideas?
 * I must admit I don't move pages oftern. Try putting the 'move' right in the namespace independant list. Let me know. Jean-Lou Dupont 20:05, 12 October 2007 (UTC)

Putting "move" in the independant list allows me to move pages with sysop accounts, but not with normal users. Is there a way to give an independant permission to other groups? UPDATE: just found that I had to do the same with "upload"

I've also had to make a few other changes to fix a few errors:


 * Added patrolmarks to dependant list to stop an error from appearing on the recentchanges page


 * caching the permissions page didn't seem to work for me, so I commented out the caching code and am just having the extension parse the registry page


 * commented out line 191 in hnp.body.php to prevent continuous debug spam from appearing on special pages
 * I have found some corner case issues. I will be fixing them shortly. Thanks for your patience. Jean-Lou Dupont 21:04, 13 October 2007 (UTC)
 * New version (1.0.1) available through PEAR or SVN. Jean-Lou Dupont 21:25, 13 October 2007 (UTC)

Still having some problems with moving and uploading, trying either action with an account that supposedly has permission for it gives a "HNP: action upload namespace dependent but called from NS_SPECIAL" behind a permission error screen. Moving them to the independant list causes the PHP error to go away, but I still get a permission error page with non-sysop accounts.
 * Could you show me the configuration you are using? i.e. your MediaWiki:Registry/HNP.Jean-Lou Dupont 18:45, 15 October 2007 (UTC)

Here it is:

Group Hierarchy Definition
Hierarchy:

Group Rights

 * I am not sure that MediaWiki supports mixed case group names. Try with only lower case names. Jean-Lou Dupont 07:06, 16 October 2007 (UTC)

Switched everything to lowercase, still getting the same behavior. I've just commented out the auth code for upload/move for now.
 * Aren't you using BizzWiki? Maybe I wrongfully assumed you were also using Extension:BizzWiki. You need this extension in order to properly manage those rights. There are patches for Special:Movepage. I should have thought about asking this question early; my sincere apologies. Jean-Lou Dupont 18:46, 23 October 2007 (UTC)


 * For uploads, I found that you have to give the groups you want to allow uploading additional rights for the Image namespace -- in particular 'edit' and 'create'. The wiki checks if the uploading user has that rights before it even uploads anything. If you do not have that rights, the 'protected page' error is displayed. Note, that you will probably also want to give the 'delete' right in order to allow users do delete images/files they have uploaded. -- Regards, Robert

Insert non-formatted text here