Block ethernet port for single account

October 30, 2018 at 10:27:39
Specs: Windows 7
Hi, just wondered if it's possible to block access to the internet on another account on a computer, when an ethernet cable's plugged in.

I share a computer and we each pay for and use separate internet connections. I use the broadband, my brother uses a wifi dongle. However, on his account it automatically connects to the broadband when an ethernet cable is connected. If he disables it on his account, it disables access on mine too.

Is there a way of disabling access to the wired broadband on his account so that it will only connect to his wifi dongle, while still defaulting to the broadband through an ethernet cord on mine?

Sounds stupid, I know:D


See More: Block ethernet port for single account

Reply ↓  Report •

#1
October 30, 2018 at 13:58:15
If you're both sharing the same internet service, why does it matter if the connection is wired or wireless? Is it not a set monthly fee with unlimited data?

Reply ↓  Report •

#2
October 30, 2018 at 21:39:52
It is possible to create a task in "task scheduler"?
Create a batch file "no_network.bat" (<any name>.bat)
Add line to batch file: netsh interface set interface "Local Area Connection" Admin=disabled
The "Local Area Connection" should match the LAN port to be disabled
Save the file to a folder accessible to the user.

Open "Task scheduler":
From the Action Menu > Create basic task
Enter a name and optional some comments > Next
Select for Trigger: "When I log on" > Next
Select for Action: "Start a program" > Next
Enter/browse the batch file created > Next > Finished

Open the new task properties:
General tab: Check the "Run with highest privileges" > OK
Triggers tab: edit the first line available in the list > Change the "Specific user" to the targeted user

If the targeted user has admin rights he can easily re-enable the LAN adapter....


message edited by sluc


Reply ↓  Report •

#3
November 5, 2018 at 05:18:48
with this script you're still hoping your brother doesnt know how to re-enable the ethernet connection, if he does know don't try this one

lookup what connection to disable from cmd.exe:

example:

netsh interface show interface


Admin State State Type Interface Name
-------------------------------------------------------------------------
Enabled Connected Dedicated VMware Network Adapter VMnet1
Enabled Connected Dedicated VMware Network Adapter VMnet8
Enabled Disconnected Dedicated Draadloze netwerkverbinding
Enabled Connected Dedicated LAN-verbinding

to disable LAN-verbining type:

netsh interface set interface LAN-verbinding disable


this is the .bat script which will automate the task at startup (not sure if admin rights are necessary)


::start of batch script
@echo off
if "%USERNAME%"=="YOURBROTHERSUSERNAME" (
netsh interface set interface LAN-verbinding disable
) else (
netsh interface set interface LAN-verbinding enable
)

::end of batch script

place it here:
C:\Users\YOURUSERNAME\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup

please replace YOURBROTHERSUSERNAME and LAN-Verbinding to whatever your needs are

and you may or may not have to also place it in:
C:\Users\YOURBROTHERSUSERNAME\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup

if you have questions please ask.

i5-6600K[delid]@4.8GHz/4.4GHz@1.424v LLC=6 | 2x4GB Crucial-DDR4-2133CL15@14-14-14-28 1T 2800MHz@1.37v
MSI Armor RX 570 4GB@1400Mhz core@1.18v/1950MHz


Reply ↓  Report •
Related Solutions


Ask Question