Hi!
I have a strange error in a console application that is hosted by IIS 5.0
and invokes a web service hosted on the same machine.
A request form the web comes in and it is dispatched to a service class
which uses a helper class to create an instance of the automatically
generated webservice proxy class. The instance creation fails on this row:
_10._0._40._252.ETISXTeeService srv = new
ETISXtee._10._0._40._252.ETISXTeeService();
with this exception:
System.ArgumentException: Illegal characters in path
the full stack trace:
Error: System.ArgumentException: Illegal characters in path.
at
System.Security.Permissions.FileIOPermission.HasIllegalCharacters(String[]
str)
at
System.Security.Permissions.FileIOPermission.AddPathList(FileIOPermissionAccess
access, AccessControlActions control, String[] pathListOrig, Boolean
checkForDuplicates, Boolean needFullPath, Boolean copyPathList)
at
System.Security.Permissions.FileIOPermission..ctor(FileIOPermissionAccess
access, String path)
at System.AppDomainSetup.VerifyDir(String dir, Boolean normalize)
at System.AppDomainSetup.get_ConfigurationFile()
at System.Configuration.ClientConfigPaths..ctor(String exePath, Boolean
includeUserConfig)
at System.Configuration.ClientConfigPaths.GetPaths(String exePath,
Boolean includeUserConfig)
at System.Configuration.ClientConfigurationHost.get_ConfigPaths()
at System.Configuration.ClientConfigurationHost.GetStreamName(String
configPath)
at System.Configuration.ClientConfigurationSystem..ctor()
at System.Configuration.ConfigurationManager.EnsureConfigurationSystem()
at System.Configuration.ConfigurationManager.EnsureConfigurationSystem()
at System.Configuration.ConfigurationManager.GetSection(String sectionName)
at System.Configuration.PrivilegedConfigurationManager.GetSection(String
sectionName)
at System.Diagnostics.DiagnosticsConfiguration.GetConfigSection()
at System.Diagnostics.DiagnosticsConfiguration.Initialize()
at System.Diagnostics.Switch.InitializeConfigSettings()
at System.Diagnostics.Switch.InitializeWithStatus()
at System.Diagnostics.Switch.get_SwitchSetting()
at System.Diagnostics.BooleanSwitch.get_Enabled()
at System.Xml.Serialization.TempAssembly.LoadGeneratedAssembly(Type type,
String defaultNamespace, XmlSerializerImplementation& contract)
at System.Xml.Serialization.XmlSerializer.FromMappings(XmlMapping[]
mappings, Type type)
at System.Web.Services.Protocols.SoapClientType..ctor(Type type)
at System.Web.Services.Protocols.SoapHttpClientProtocol..ctor()
at ETISXtee._10._0._40._252.ETISXTeeService..ctor() in E:\Documents and
Settings\juhan\My Documents\Visual Studio\Projects\ETISXtee\ETISXtee\Web
References\10.0.40.252\Reference.cs:line 189
at ETISXtee.Utils.prepareService() in E:\Documents and Settings\juhan\My
Documents\Visual Studio\Projects\ETISXtee\ETISXtee\Utils.cs:line 20
at ETISXtee.ServiceReturnCountryList.composeBody(Object input) in
E:\Documents and Settings\juhan\My Documents\Visual
Studio\Projects\ETISXtee\ETISXtee\ServiceReturnCountryList.cs:line 22
the same webservice is correctly invoked by a test client created using
windows forms.
Of course I have googeled, but i have yet to find a solution :( any help
would be appreciated
Juhan

Signature
ASP.NET Developer, MCSD
Martin Kulov - 12 Jan 2006 23:14 GMT
> Hi!
>
[quoted text clipped - 13 lines]
>
> the full stack trace:
....
> Juhan
Hi Juhan,
It seems to me that there is some bad data in a switch configuration section
in your config file. Can you paste the config file?
Regards,

Signature
Martin Kulov
http://www.codeattest.com/blogs/martin
MCAD Charter Member
MCSD.NET Early Achiever
MCSD
Juhan - 13 Jan 2006 06:32 GMT
Hi Martin
Thanks for your reply. the configuration file is as follows:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<sectionGroup name="applicationSettings"
type="System.Configuration.ApplicationSettingsGroup, System, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089" >
<section name="ETISXtee.Properties.Settings"
type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</sectionGroup>
</configSections>
<applicationSettings>
<ETISXtee.Properties.Settings>
<setting name="ETISXTeeService" serializeAs="String">
<value>http://10.0.40.252/xteewebservice/etisxteeservice/etisxteeservice.asmx</value>
</setting>
</ETISXtee.Properties.Settings>
</applicationSettings>
</configuration>
Other things I should have mentioned: I am dealing with .net 2.0 and the
same problem occurs also on iis 6.0
Juhan

Signature
ASP.NET Developer, MCSD
Juhan - 16 Jan 2006 14:00 GMT
I haven't still found a solution for my problem. Little more additional info:
the webservices I am using are the Sql 2005 endpoints. Could this be somekind
of a security issue?
Juhan

Signature
ASP.NET Developer, MCSD