Is is safe to backup programming projects (for example websites that where made using HTML/CSS/JS with the help of some frameworks and libraries (Bootstrap, jQuery, etc.), C# projects made with the .NET framework or websites with backend made with PHP) from a possibly infected computer? What messures can I take to backup those programming projects and making sure they are not infected?
If you're concerned enough about it to wipe the machine, and you don't already have an online repository for your code somewhere like Github, then I'd suggest getting a live boot CD/USB for a Linux distribution of your choice and use that to copy the files off to external storage or cloud storage. I don't know of any way other than manually inspecting your code for changes to check for malicious modifications, however I would deem that incredibly unlikely for personal code projects unless they are widely in use by others.
Then get a real version control system with online hosting. This should be as simple as "download latest version from online repository, compare with local" in the worst case but that only works if you have said online repository.
- Upload the files to pastebin, let pastebin convert to plain text
- Open the pastebin file from your clean machine Copy from the browser, paste to a new file
- Use your non-personal Gmail, share a folder such that anyone can edit
- upload your code (but not your boilerplate) to the folder
- Or email it to gmail either way, Google will AV scan it for you
- From Google put it into Github, let Github do the protocol conversion. Open as RAW and save
Once it is in Google then you can go to your good machine and delete all the boilerplate files, eg Bootstrap as well as any non-text files. You can view the files in Google.
I would assume that there is some crafty way to attach malware data into a text file by fiddling with the filesize indicator/EOF indicator (I can't think how you would do that but assume it is so) and i would assume that every file that ends in .php / .txt / .whatever is actually a binary with the wrong file extension or a hidden extension.
Putting these files into a third party sandpit allows you to look at them.
Depends on how through you want to be. In all scenarios, Isolate the infected pc, no internet, no lan, Bluetooth, no nothing.
Option extremis: Give a human a pc and copy the code using his eyes into a new solution on a safe pc. That will take a ton of time, but reviewing the code is the best way to ONLY take the code, no problem of a bing/exe/whatevers with malicious code.
Middle of the road: Copy on a flash drive the code as plain text. Use any tool you prefeer to scan any potential threat that goes in the flash drive. That saves time manually writing all the code, yet you don't actually know the contents with the same level of confidence.
Middlish of the road: Perform a clean on the solutions and copy those files. Here you also bring *sln, xmls, etcs. So more chance for a surprise. Way faster too.
And after you take the info you need, nuke the system from orbit!