That's exactly what I was thinking, since that's kind of what NLA was designed 
for, couldn't it be leveraged? 

Actually went down the rabbit hole to look at it this AM to satisfy my 
curiosity but wsck got in the way :-]

-----Original Message-----
From: Steve Kradel [mailto:[email protected]] 
Sent: Thursday, August 16, 2012 12:51 PM
To: NT System Admin Issues
Subject: Re: Offline/online detection

AFAIK the built-in network location bits in Vista and later use the 
reachability of a domain controller to decide when to use the Domain / Private 
/ Public network profiles.  I'd probably do the same thing in an app, rather 
than ICMP ping, to avoid spoofing, including the horrible DNS default responses 
that some ISPs perpetrate upon their customers.

An even lazier approach might be to use the return code of nltest...

--Steve

On Thu, Aug 16, 2012 at 8:56 AM, James Rankin <[email protected]> wrote:
> Yes, the possibilities of users disconnecting mid-session really makes 
> this a minefield, to be fair. Almost looks as though ping will be the 
> best way to do this, running the "Online Check" at a particular process start 
> point.
>
> Just need to dust my VB off I guess - for some reason the person 
> requesting this wants it as a VBScript rather than a batch command. 
> PITA - I had an old batch script I could have repurposed in five minutes.
>
> Cheers,
>
>
>
>
> JR
>
>
> On 16 August 2012 12:31, Ben Scott <[email protected]> wrote:
>>
>> On Thu, Aug 16, 2012 at 6:56 AM, James Rankin <[email protected]>
>> wrote:
>> > I have to say that using ping seems a tad - well, anachronistic.
>>
>>   Why?  It's specifically designed to see if a host is reachable -- 
>> almost exactly what you want to do, no?
>>
>>   Simple is good.
>>
>> > I'd have thought there might be a Registry key that indicated an 
>> > offline logon or something simple like that ...
>>
>>   Well, if I understand it correctly, that's not really what you want 
>> to do.  You don't really care how they logged on, you care how the 
>> app is running.  Right?
>>
>>   For example, what if I log on to the corporate network, but then 
>> undock and take my laptop to lunch (without shutting down), and then 
>> run the app?
>>
>>   Be wary of solving the wrong problem.  :)
>>
>> -- Ben
>>

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
<http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/>  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to [email protected]
with the body: unsubscribe ntsysadmin


PG&E is committed to protecting our customers' privacy. 
To learn more, please visit http://www.pge.com/about/company/privacy/customer/

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ <http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/>  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to [email protected]
with the body: unsubscribe ntsysadmin

Reply via email to