Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / December 2007

Tip: Looking for answers? Try searching our database.

Error when try to encrypt connectionstring using aspnet_regiis -pe

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
rockdale - 20 Dec 2007 15:46 GMT
I followed this article,

http://msdn2.microsoft.com/en-us/library/zhhddkxy.aspx

My command is:
aspnet_regiis -pe "connectionStrings" -app "/myWebSiteName" -site
711831 -prov "RsaProtectedConfigurationProvider"

The error message is: A configuration file cannot be created for the
requested configuration object.
Failed!

ASPNET user is under administrators group
my website is not a virtual directory under default website, that's
why I need to specify the site no.
OS is Windows 2003 server

Am I missing anything?

Thanks in advance
-rockdale
Alexey Smirnov - 20 Dec 2007 19:17 GMT
> I followed this article,
>
[quoted text clipped - 17 lines]
> Thanks in advance
> -rockdale

Try to use -location instead of -app -site. App exprected a virtual
path.

aspnet_regiis.exe /?

-pe section         Encrypt the configuration section. Optional
arguments:
                   [-prov provider] Use this provider to encrypt.
                   [-app virtual-path] Encrypt at this virtual path.
Virtual
                   path must begin with a forward slash. If it is
'/', then it
                   refers to the root of the site. If -app is not
specified,
                   the root web.config will be encrypted.
                   [-site site-name-or-ID] The site of the virtual
path
                   specified in -app. If not specified, the default
web site
                   will be used.
                   [-location sub-path] Location sub path.
                   [-pkm] Encrypt/decrypt the machine.config instead
of
                   web.config.
Mohamad Elarabi - 20 Dec 2007 19:23 GMT
Did you try doing a aspnet_regiis -pef instead of -pe? You can then reference
the config file's physical path and avoid the hassle. I've always used that
anyways. To me it seems more precise and less blackboxish.

Signature

Mohamad Elarabi
Lead Developer. MCTS, MCPD.

> I followed this article,
>
[quoted text clipped - 17 lines]
> Thanks in advance
> -rockdale

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.