Security Scan SCS0018 Warnings in Visual Studio are shown during the build. Currently, I am working on these warnings to get removed. I tried several MSDN sites but no luck. I have also read OWSAP but they are not clearly related to C#. Please find the image of Path Traversal warning.
Code:
public void Move(string sourceFileName, string destinationFileName) { try { System.IO.File.Move(sourceFileName,destinationFileName); } catch (System.Exception e) { } }

You should read the docs on this warning to understand the problem and find relevant references.
https://security-code-scan.github.io/#SCS0018
The problem with your code is that you accept and use the
destinationFileNameparameter without any kind of checking.The documentation provides a recommendation (checking for invalid filename chars and throwing an exception before using the parameter) and .NET Core provides a new type, PhysicalFileProvider, that may protect from path traversal.
But, I don't know if SCS detects usage of this type correctly.