/build/static/layout/Breadcrumb_cap_w.png

Office activation with a proxyserver

I'm trying to activate Office 2010 by running the OSPP.VBS script. I'm using the following command : cscript OSPP.VBS /act in the correct directory. This works fine but when I'm trying to run the same script as a postinstallation task, the following error occurs : 0x80072EE2 a timeout error.

The computers are all in a domain and they're accesing the internet over a proxyserver. We've added several exceptions in the proxyserver but it still doesn't work. Is there any of you guys who knows an answer?

 


0 Comments   [ + ] Show comments

Answers (3)

Posted by: dchristian 11 years ago
Red Belt
2

How is your proxy settings being applied? Through GPO or post-install taks? Are you sure they have the proxy configuration applied when they're attempting to communicate? You may need to setup the proxy first, then try to activate.

Posted by: flabdablet 10 years ago
White Belt
1

I've just wrestled this one to the ground.

The issue appears to be that ospp.vbs ignores the WINHTTP proxy settings. Instead, it uses the proxy settings defined under Internet Options for the current user. If you're doing stuff from a startup script or something else that runs as the SYSTEM user, there's no obvious way to define those settings so ospp.vbs will attempt to connect directly and time out.

Here's the script fragment I use to activate Office 2010, which gets called from startup and shutdown scripts:

set return=goto :eof

call :setproxy
set ospp=cscript /nologo "%ProgramFiles%\Microsoft Office\Office14\ospp.vbs"
set ospplog="%temp%\ospp.log"
%ospp% /osppsvcrestart >%ospplog% || %return%
%ospp% /act >>%ospplog% || %return%
findstr /c:"Product activation successful" %ospplog% || %return%
%setflag% office-2010
%return% :setproxy
setlocal enabledelayedexpansion
set key=HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Connections
set val=DefaultConnectionSettings
set type=REG_BINARY
set setting=09
rem settings: 01 = none, 03 = use proxy, 05 = use script, 09 = auto detect; bitwise OR as needed
for /f "tokens=1-3" %%A in ('reg query "!key!" /v "!val!"') do if "%%A %%B"=="!val! !type!" set data=%%C
set data=!data:~,16!!setting!!data:~18!
reg add "!key!" /v "!val!" /t !type! /d !data! /f
endlocal
%return%

The /osppsvcrestart step is there to prevent the intermittent failures I saw, apparently caused by the OSPP service already having been started before the proxy settings are changed.

My site is set up to push out proxy settings using WPAD. If you're using a statically defined proxy instead, :setproxy will be much less unreasonable because there will be no need for the REG_BINARY foolery needed to turn on proxy auto-detection. Something like this should work:

:setproxy
setlocal enabledelayedexpansion
set ProxyServer=http=proxy.example.lan:3128;https=proxy.example.lan:3128
set ProxyOverride=localhost;*.admin.lan;127.*.*.*
set key=HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings
reg add "!key!" /v "ProxyServer" /d "!ProxyServer!" /f
reg add "!key!" /v "ProxyOverride" /d "!ProxyOverride!" /f
reg add "!key!" /v "ProxyEnable" /t REG_DWORD /d 1 /f
endlocal
%return%

 

Posted by: andemats 11 years ago
2nd Degree Black Belt
1

Here's a link to the Microsift kb of the error.

http://support.microsoft.com/kb/836941/en

These errors may be caused by any of the following issues:

  • Applications or processes that interfere with Internet communications
  • Resource issues on your computer
  • High Internet activity
  • Recoverable database errors

Comments:
  • I think a proxy server probably counts as "applications or processes that interfere with Internet communications". - flabdablet 10 years ago

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

View more:

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ