Home | Download | Demo | Feature list | Premium users | Support | Knowledgebase
How to fix WMI Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
The network path was not found - The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)
How to configure Windows Vista clients.
How to configure the windows firewall using group policies.
   
Welcome Guest Search | Active Topics | Members | Log In | Register

Access to Lansweeper by group membership Options
BullGates
Posted: Wednesday, April 16, 2008 4:16:40 PM

Rank: Premium user
Groups: Member , Premium Users

Joined: 9/29/2007
Posts: 44
Location: PT
Well, maybe this can help someone, so here goes a simple way to restrict access to the lansweeper site.

Add to your existing web.config file in the Lansweeper directory on your IIS server these lines:
Code:
<system.web>
    <authentication mode="Windows"/>
    <identity impersonate="true" />
    <compilation debug="true"/>
<authorization>
<allow roles="domain\allowed_group" />
<deny users="*" />
</authorization>
</system.web>
</configuration>


Any users that bellong to group domain\allowed_group will be able to use Lansweeper, all the others will be denied. if you need more than one group, just add them comma separated:
Code:
<allow roles="domain\allowed_group1,domain\allowed_group2,domain\allowed_group3" />
xhen
Posted: Friday, April 25, 2008 10:06:24 PM
Rank: Freeware Member
Groups: Member

Joined: 4/25/2008
Posts: 10
Location: Spain
have you got something similar for users?
I want my boss access only not all the group members of his group

thxApplause
Lansweeper
Posted: Sunday, April 27, 2008 10:17:35 AM

Rank: Administration
Groups: Administration

Joined: 2/10/2005
Posts: 1,451
Location: Hamme Belgium
Something like this should do the trick

Code:
<authorization>
<allow users="bossusername" />
<deny users="*" />
</authorization>
xhen
Posted: Monday, April 28, 2008 5:56:02 PM
Rank: Freeware Member
Groups: Member

Joined: 4/25/2008
Posts: 10
Location: Spain
Io I have made this changes in webconfig
<configuration>
<appSettings>
<add key="MM_CONNECTION_HANDLER_Lansweeper" value="sqlserver.htm" />
<add key="MM_CONNECTION_STRING_Lansweeper" value="Persist Security Info=False;Data Source=172.24.40.4\sqlexpress;Initial

Catalog=Lansweeper;User ID=lssqluser;Password=qaz65214" />
<add key="MM_CONNECTION_DATABASETYPE_Lansweeper" value="SQLServer" />
<add key="MM_CONNECTION_SCHEMA_Lansweeper" value="" />
<add key="MM_CONNECTION_CATALOG_Lansweeper" value="" />
<add key="dateformat" value="dd/MM/yyyy" />
</appSettings>
<system.web>
<authentication mode="Windows"/>
<identity impersonate="true" />
<compilation debug="true"/>
<authorization>
<allow roles="domain\sysadmin" />
<allow users="arturo.martinez" />
<deny users="*" />
</authorization>
<compilation debug="true"/>
</system.web>
</configuration>

and I have received this error trying accesing from another computer

Quote:
Runtime Error
Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".

<!-- Web.Config Configuration File -->

<configuration>
<system.web>
<customErrors mode="Off"/>
</system.web>
</configuration>


Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.

<!-- Web.Config Configuration File -->

<configuration>
<system.web>
<customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
</system.web>
</configuration>


and this error in the local server
Quote:

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Sections must only appear once per config file. See the help topic <location> for exceptions.

Source Error:


Line 17: <deny users="*" />
Line 18: </authorization>
Line 19: <compilation debug="true"/>
Line 20: </system.web>
Line 21: </configuration>


Source File: C:\lansweeperpro\website\web.config Line: 19
Lansweeper
Posted: Monday, April 28, 2008 7:23:14 PM

Rank: Administration
Groups: Administration

Joined: 2/10/2005
Posts: 1,451
Location: Hamme Belgium
xhen wrote:
Io I have made this changes in webconfig
<configuration>
<appSettings>
<add key="MM_CONNECTION_HANDLER_Lansweeper" value="sqlserver.htm" />
<add key="MM_CONNECTION_STRING_Lansweeper" value="Persist Security Info=False;Data Source=172.24.40.4\sqlexpress;Initial

Catalog=Lansweeper;User ID=lssqluser;Password=qaz65214" />
<add key="MM_CONNECTION_DATABASETYPE_Lansweeper" value="SQLServer" />
<add key="MM_CONNECTION_SCHEMA_Lansweeper" value="" />
<add key="MM_CONNECTION_CATALOG_Lansweeper" value="" />
<add key="dateformat" value="dd/MM/yyyy" />
</appSettings>
<system.web>
<authentication mode="Windows"/>
<identity impersonate="true" />
<compilation debug="true"/>
<authorization>
<allow roles="domain\sysadmin" />
<allow users="arturo.martinez" />
<deny users="*" />
</authorization>
<compilation debug="true"/>
</system.web>
</configuration>


You have used <compilation debug="true"/> twice
xhen
Posted: Tuesday, April 29, 2008 9:28:36 AM
Rank: Freeware Member
Groups: Member

Joined: 4/25/2008
Posts: 10
Location: Spain
ok done it!! now works perfect!!
thanks a lot!
AstraBreak
Posted: Wednesday, May 14, 2008 4:42:20 PM
Rank: Freeware user
Groups: Member

Joined: 5/14/2008
Posts: 1
Location: Belgium
Don't forget the following steps in IIS
1. Anonymous access must be disabled
2. Integrated Windows authentication must be enabled

Thanks for this post ...
TelhioCU
Posted: Thursday, October 16, 2008 8:21:50 PM

Rank: Premium user
Groups: Member , Premium Users

Joined: 10/6/2008
Posts: 16
Location: Columbus, Ohio
Ok, this is getting insane!

Here is my web.config:

<configuration>
<appSettings>
<add key="MM_CONNECTION_HANDLER_Lansweeper" value="sqlserver.htm"/>
<add key="MM_CONNECTION_STRING_Lansweeper" value="Persist Security Info=False;Data Source=BR01SQL03;Initial Catalog=Lansweeper32;User ID=xxxxxxx;Password=xxxxxx"/>
<add key="MM_CONNECTION_DATABASETYPE_Lansweeper" value="SQLServer"/>
<add key="MM_CONNECTION_SCHEMA_Lansweeper" value=""/>
<add key="MM_CONNECTION_CATALOG_Lansweeper" value=""/>
<add key="dateformat" value="dd/MM/yyyy"/>
</appSettings>
<system.web>
<authentication mode="Windows"/>
<identity impersonate="true" />
<compilation debug="true" strict="false" explicit="true">
<authorization>
<allow roles="domain\group name" />
<deny users="*" />
</authorization>
<assemblies>
<add assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Web.Extensions.Design, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
</assemblies>
</compilation>
<httpHandlers><remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx" type="System.Web.Script.Services.ScriptHandlerFactory" validate="false"/>
<add verb="*" path="*_AppService.axd" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
</httpHandlers>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</httpModules>
</system.web>
</configuration>

Now it is giving me this error message:

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized element 'authorization'.

Source Error:


Line 12: <identity impersonate="true" />
Line 13: <compilation debug="true" strict="false" explicit="true">
Line 14: <authorization>
Line 15: <allow roles="domain\group name" />
Line 16: <deny users="*" />


Source File: C:\Program Files\lansweeper32\website\web.config Line: 14

Is it really this hard?

UGH!


Lansweeper
Posted: Thursday, October 16, 2008 8:50:03 PM

Rank: Administration
Groups: Administration

Joined: 2/10/2005
Posts: 1,451
Location: Hamme Belgium
Could you upload (as attachment) your complete web.config file please.

Could you also upload a complete screenshot of the webpage error that you are getting.
DavidMS1
Posted: Wednesday, October 29, 2008 4:57:07 PM
Rank: Freeware user
Groups: Member

Joined: 10/29/2008
Posts: 8
Location: Bethesda, MD
I am having the same problem.

Quote:
<configuration>
<appSettings>
<add key="MM_CONNECTION_HANDLER_Lansweeper" value="sqlserver.htm"/>
<add key="MM_CONNECTION_STRING_Lansweeper" value="Persist Security Info=False;Data Source=HCA-BET-DEV01\SQLEXPRESS;Initial Catalog=Lansweeper32;User ID=lssqluser32;Password=mysecretpassword0*"/>
<add key="MM_CONNECTION_DATABASETYPE_Lansweeper" value="SQLServer"/>
<add key="MM_CONNECTION_SCHEMA_Lansweeper" value=""/>
<add key="MM_CONNECTION_CATALOG_Lansweeper" value=""/>
<add key="dateformat" value="dd/MM/yyyy"/>
</appSettings>
<system.web>
<compilation debug="true" strict="false" explicit="true">
<assemblies>
<add assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Web.Extensions.Design, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
</assemblies>
</compilation>
<httpHandlers>
<remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx" type="System.Web.Script.Services.ScriptHandlerFactory" validate="false"/>
<add verb="*" path="*_AppService.axd" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
</httpHandlers>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</httpModules>
</system.web>
</configuration>


The output when I attempt to connect to the server looks like this:

Quote:
Server Error in '/lansweeper32' Application.


Runtime Error
Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".


<!-- Web.Config Configuration File -->

<configuration>
<system.web>
<customErrors mode="Off"/>
</system.web>
</configuration>


Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.


<!-- Web.Config Configuration File -->

<configuration>
<system.web>
<customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
</system.web>
</configuration>



Can you please let us know. I would realy like to use lansweeper for our inventory solution, but need to lock unauthroized users out. Let me know if you need anything else.

Thanks in advance,

David
Users browsing this topic
Guest


Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.


Copyright © 2003-2006 Yet Another Forum.net. All rights reserved.

   
Quick links: Download - Premium users - Support 
Copyright 2004 - 2008 © Geert Moernaut - Hemoco bvba - All rights reserved