Closed bkarakaya01 closed 9 months ago
Hi
I think we can solve this problem quicky, my proposal
use WebTldRuleProvider
-> inject a own instance of FileCacheProvider
we change the FileCacheProvider
with an option to disable var tempPath = Path.GetTempPath();
and allow own path
use
WebTldRuleProvider
-> inject a own instance ofFileCacheProvider
we change theFileCacheProvider
with an option to disablevar tempPath = Path.GetTempPath();
and allow own path
Yes, I guess this is a right way of solving the issue. Thank you.
When using the
DomainParser
class withWebTldRuleProvider
and default settings, I am encountering the following errorAccess to the path 'C:\Windows\TEMP\publicsuffixcache.dat' is denied
in the real server environment.This problem can be overcome by the following two methods:
Use a
FileTldRuleProvider
, so that the file can be saved and used under the root folder of the application.As "Microsoft's Application Pool Identities Documentation" states, you can find the publicsuffixcache.dat' file, and then you can arrange the permissions by right clicking file and following Properties - Security - Edit - Add - Enter the object names to select (Write Users and Check Names) - OK. So you have to give permissions to Users.
I didn't like choosing the second option because I thought it would create security vulnerabilities (maybe I'm thinking wrong) and it would be hard to manage in case of multiple servers . Likewise, I may not want to work with a local file, thus i may not use FileTldRuleProvider.
In such a situation, I could not find how to overcome this problem. I will be glad if you help me. For now, I have basically solved the problem, but I am writing here to understand the source of the problem. Also, if someone is stuck like me, maybe it will be useful information.