#193515 - 2009-04-19 05:04 PM
IE Setup / RunOnce and PhishingFilter
|
JWisham
Fresh Scripter
Registered: 2009-04-19
Posts: 5
Loc: AL, USA
|
Hey everyone, brand new to the forums.
Have a few specific keys that we are trying to setup/create upon login that (alone) don't seem to work (while the rest of the script is perfect).
The only "common thread" I could find is that these registry keys don't exist at all. These logins are new, and have never logged into the network or locally on those machines previously - most will take place on XP machines.
The three registry keys (or commands, I should say) we have trouble with are:
WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main", "RunOnceHasShown", 1, "REG_DWORD") WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main", "RunOnceComplete", 1, "REG_DWORD") WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\PhishingFilter", "Enabled", 2, "REG_DWORD")
This is trying to circumvent and streamline the usage of IE once they login.
Just a heads up: I did actually try searching using writevalue, runonce, and phishingfilter but didn't get any results back on the BB, so I figured I'd start a new topic in case someone else is trying these specific registry modifications and is also having trouble.
(in comparison, start page works fine): WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main", "Start Page", "http://*************.com", "REG_SZ")
That one has no trouble at all. So, the only difference I could determine was the registry keys don't exist prior to opening IE for the first time. Very strange, since I know WriteValue is designed to write a registry key to start with, if it doesn't see it present at the time.
Any suggestions?
|
|
Top
|
|
|
|
#193519 - 2009-04-20 11:42 AM
Re: IE Setup / RunOnce and PhishingFilter
[Re: Arend_]
|
Mart
KiX Supporter
   
Registered: 2002-03-27
Posts: 4673
Loc: The Netherlands
|
Yeah, I know.
I just asked the OP about the setup he has.
For IE8 you have these keys and values:
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main] "IE8RunOnceLastShown"=dword:00000001 "IE8RunOnceLastShown_TIMESTAMP"=hex:d0,0e,71,6a,ce,b5,c9,01 "IE8RunOncePerInstallCompleted"=dword:00000001 "IE8RunOnceCompletionTime"=hex:40,c3,35,84,ce,b5,c9,01 "IE8TourShown"=dword:00000001 "IE8TourShownTime"=hex:60,65,08,61,37,b7,c9,01
_________________________
Mart
- Chuck Norris once sold ebay to ebay on ebay.
|
|
Top
|
|
|
|
#193521 - 2009-04-20 11:22 PM
Re: IE Setup / RunOnce and PhishingFilter
[Re: Mart]
|
JWisham
Fresh Scripter
Registered: 2009-04-19
Posts: 5
Loc: AL, USA
|
Thanks for the welcoming 
Yes, this is actually for IE7, not IE8.
I did a bit of searching around, and found that these are, in fact, the correct registry settings. For example, if I create a registration file and merge it manually, these exact same settings work perfectly each time.
Its just strange that the phishing filter and runonce registry keys do not, as opposed to the start page / homepage registry key when used with kixtart.
Thanks,
Jared
|
|
Top
|
|
|
|
#193522 - 2009-04-20 11:25 PM
Re: IE Setup / RunOnce and PhishingFilter
[Re: JWisham]
|
JWisham
Fresh Scripter
Registered: 2009-04-19
Posts: 5
Loc: AL, USA
|
.. and to answer your question,
No... the values are NOT written at all. Its like the keys don't pre-exist, so Kixtart does not write anything to them (whereas the other WriteValue, start page, changes the key appropriately).
That's why I came here - process of elimination seems to say that it is the script not changing the key as it is supposed to.
Any suggestions?
Thanks,
Jared
|
|
Top
|
|
|
|
#193526 - 2009-04-21 06:51 PM
Re: IE Setup / RunOnce and PhishingFilter
[Re: Arend_]
|
JWisham
Fresh Scripter
Registered: 2009-04-19
Posts: 5
Loc: AL, USA
|
That's awesome guys - thanks for pointing out the basic syntax was incorrect (/bonk myself for not seeing that difference to start with).
On a related note, could it also be due to having spaces between separators? There's another one that is similar we have used for years, and it seems to perform just fine, but I noticed there's no spaces. Maybe this is the way Kixtart passes the string/ints properly?
i.e.: WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\1","1406",0,"REG_DWORD")
See? That one works fine. Is this mentioned anywhere in the docs about requiring/not requiring certain syntax (spaces, no spaces, quotes, no quotes, etc.)?
|
|
Top
|
|
|
|
#193527 - 2009-04-21 07:44 PM
Re: IE Setup / RunOnce and PhishingFilter
[Re: JWisham]
|
NTDOC
Administrator
   
Registered: 2000-07-28
Posts: 11631
Loc: CA
|
Well I have to disagree on this. Taking the EXACT code from JWisham and running it works for me. In this case the expected value in the registry is an integer however I'm certain it will take a string just fine so if it's not working I have to assume that something else is at play here. I'm sure some of you other guys that might have more time to review it can track it down, but I've got some other projects I have to get done.
Even modifying his code a little it still works for me.
Variable types In KiXtart, variables are always of one fundamental data type: Variant. The current implementation of KiXtart uses three types of variants: long integers, doubles (8-byte floating point numbers) and strings. A variant of type string can contain up to 32,000 characters. Integer variables can contain any value between 2,147,483,648 and 2,147,483,647. The type of a variable is automatically changed to the result of the expression that is assigned to it. This means that if you assign a string to a variable containing an integer, the type of the variable is changed to a string.
Works fine for me.
$RC = WriteValue('HKCU\Software\Microsoft\Internet Explorer\PhishingFilter', 'Enabled', 2, REG_DWORD) Also works fine
$RC = WriteValue('HKCU\Software\Microsoft\Internet Explorer\PhishingFilter', 'Enabled', '2', REG_DWORD) Notice that even though normally you "should" put quotes on the REG_DWORD KiX is forgiving enough to allow it with no quotes, but I believe that to be an undocumented method in KiX.
|
|
Top
|
|
|
|
#193532 - 2009-04-21 10:57 PM
Re: IE Setup / RunOnce and PhishingFilter
[Re: NTDOC]
|
JWisham
Fresh Scripter
Registered: 2009-04-19
Posts: 5
Loc: AL, USA
|
Ok - the problem is actually not regarding the quotations after all..
It seems more like this is the result of a problem caused by this being the (excuse the caps) FIRST TIME THIS USER LOGS ON.
In other words, KixTart starts up, runs the logon scripts, THEN Windows shows the "Setting up personalized settings.. " eventually progressing to Media Player, and (gulp) IE.
So, is there any way to circumvent this that you guys can think of?
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 764 anonymous users online.
|
|
|