diff --git a/Source/Csla/Reflection/MethodCaller.cs b/Source/Csla/Reflection/MethodCaller.cs index e791076020..1aa039dc9f 100644 --- a/Source/Csla/Reflection/MethodCaller.cs +++ b/Source/Csla/Reflection/MethodCaller.cs @@ -252,8 +252,11 @@ public static Type GetType(string typeName, bool throwOnError, bool ignoreCase) if (splitName.Length > 2) { - var asm = AssemblyLoadContext.Default.LoadFromAssemblyPath(AppContext.BaseDirectory + splitName[1].Trim() + ".dll"); + var path = AppContext.BaseDirectory + splitName[1].Trim() + ".dll"; + if (path.Contains("..") || path.Contains(':')) + throw new TypeLoadException(path); + var asm = AssemblyLoadContext.Default.LoadFromAssemblyPath(path); return asm.GetType(splitName[0].Trim()); } else