如何在安装Clickonce应用程序时使用我的代理凭据?

时间:2013-01-02 17:35:08

标签: internet-explorer proxy clickonce

我使用经过身份验证的代理连接到互联网。代理设置列在控制面板中,我第一次连接到网站时会收到用户/密码对话框。

虽然它通常正常,但当我启动需要从互联网上下载文件的Clickonce应用程序时,我收到了这个错误:

Application download did not succeed. Check your network connection, or contact your system administrator or network service provider.

我进入了日志文件,发现了这个:

ERROR DETAILS
    Following errors were detected during this operation.
    * [22/12/2012 15:19:25] System.Deployment.Application.DeploymentDownloadException (Unknown subtype)
        - Downloading http://#######.###/########.application did not succeed.
        - Source: System.Deployment
        - Stack trace:
            at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next)
            at System.Deployment.Application.SystemNetDownloader.DownloadAllFiles()
            at System.Deployment.Application.FileDownloader.Download(SubscriptionState subState)
            at System.Deployment.Application.DownloadManager.DownloadManifestAsRawFile(Uri& sourceUri, String targetPath, IDownloadNotification notification, DownloadOptions options, ServerInformation& serverInformation)
            at System.Deployment.Application.DownloadManager.DownloadDeploymentManifestDirectBypass(SubscriptionStore subStore, Uri& sourceUri, TempFile& tempFile, SubscriptionState& subState, IDownloadNotification notification, DownloadOptions options, ServerInformation& serverInformation)
            at System.Deployment.Application.DownloadManager.DownloadDeploymentManifestBypass(SubscriptionStore subStore, Uri& sourceUri, TempFile& tempFile, SubscriptionState& subState, IDownloadNotification notification, DownloadOptions options)
            at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
            at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
        --- Inner Exception ---
        System.Net.WebException
        - The remote server returned an error: (407) Proxy Authentication Required.
        - Source: System
        - Stack trace:
            at System.Net.HttpWebRequest.GetResponse()
            at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next)

我已在用户设置中将凭据添加到“我的凭据”部分,但它仍无效。

有没有办法通过经过身份验证的代理下载Clickonce应用程序的文件?

1 个答案:

答案 0 :(得分:2)

Google搜索“clickonce中的代理凭据”并在过去一年内过滤结果我发现了这种解决方法。

如何使用ClickOnce进行代理身份验证:http://www.0x00.to/post/2012/12/31/How-to-use-ClickOnce-with-proxy-authentication

修改

https://github.com/mc-kay/ClickOnceWithProxySupport