Copying files, while preserving ALL attributes - windows

I'm trying to write a restore script for an embedded PC running Windows XP, the idea is, to plug in an restore USB flash drive, boot it and copy an image from the flash drive to the PC. That's working fine so far. However each embedded PC has an individual license file, which needs to be preserved.
I'm trying to copy these files to flash drive, restore the image and copy them back to the PC.
If I copy them using Windows Explorer, they are are ok.
If I copy them using command lines "copy" or "xcopy" they break. The also break when I use C# and File.Copy, so I guess there are some attributes which are not covered.
Any ideas how to copy these files without the need to log in (they usally don't have any kind of display or keyboard)?
Note that the license files are bound to hardware id, i'm not trying to pirate anything.

Related

Windows is hacked - All file's extension have changed

We have a Microsoft Windows server, we find all files changed to an extension .ETH file (Specially the AutoCAD files .dwg files).
As the following:
All files converted to .id-26E67253.[helpfilerestore#india.com].ETH.
Also, If I tried to connect any flash USB to the computer, all files inside the USB Drive hacked also.
I just need any suggestion, how can I get my old files, and how can I fix the virus or hacking?
It is a ransomware named Dharma.
Check this link Dharma Ransomware

How to copy files on a CMD on LAN (windows xp)

hello I don't know about this but I found this on Internet cafe but I don't have enough knowledge on how .bat files works, So I want to know how to copy files like this display.
And the files is already shared so that I can copy. All PC don't have password. Just directly log-in to desktop.
Input location to copy: \\PC1\Steam\Steam\SteamApps\common\dota 2 beta
Input location to paste: D:\Games\Steam\SteamApps\common\dota 2 beta
then it will alert me if done. The files will be overwrite and paste all data.
I don't know the code of copying too and I search too many still cant understand. I just want to use this on my internet cafe so that I don't update games anymore on every PC. Because copying on directly network is my costumer don't know.
Copy -y "source" "destination".
With the quotes if there are spaces in the path. Also, if copy does not want to copy from the network unc, then first connect to the unc using "net use".

Virtual Box Shared folders on Mac backup to external harddrive

So I found out how to share folders using Virtual Box and running Windows 8.
I was wondering, if I save files or projects from Windows 8 to the shared folder on my Mac, will TimeMachine backup those files onto my external harddrive? The hard drive is of course formatted for Mac because of that whole debockel, but that is besides the point. Even though the files were made in Windows.
Also...My assumption is that I would not be able to access the files on my external formatted hard drive from Virtual Box running Windows 8. Is this true?
To my knowledge, you cannot access the files on a journaled formatted hard drive from Windows without extra software. If I understand you correctly, you are trying to backup files created in the Windows VM within your Time Machine backup hard drive?
I'm sure you have solved this by now, but you should consider backing up the VM itself. If the files on the Windows Machine are important you can leave them in a shared folder and have time machine back up that folder.

How to specify the folder in which the applications should get installed on Mac?

I find that when I install applications(.dmg files), they all are installed into the folder /Volumes.And some days ago, they were installed into the folder /Applications. I don't know my macbook had suffered what kind of attacks, improper use or something like these. Anyway, it changed. I don't know how to resolve it. Is there anyone who ever had that kind of problem like me?Anyone who know how to make my macbook back to install applications into /Applications folder by default?Or anyone who know how to specific the installing folder if the default installing folder is not I want?
You need to begin by understanding the difference between installing and application and running it from a disk image. The whole disk image situation is understandably confusing for users, but considering that this is a programming Q&A, here are the important points.
Macintosh applications are stored in special directories with the extension .app. Because of the extension, these files are known by the Finder and treated as special Bundles, which are shown to the user as a single icon which cannot easily be opened further (there are other types of bundles as well, but the .app bundles deal specifically with applications.
Because Macintosh applications are actually directories full of files and other directories, they cannot be downloaded as a single file through the Internet without some kind of packaging. Recently there has been a move to package these in standard zip files, because they are understood well by many platforms. For many years prior to this, though, Macintosh applications were distributed on mountable Disk Images (.dmg format files), which themselves were multi-file containers which could support a variety of files and directories.
The key problem in both cases is that applications, once downloaded, don't necessarily move themselves to the most obvious location (the Applications folder on the boot volume, where Apple-installed applications are stored). Zip files usually automatically decompress, but are left inside of your Downloads directory, and Disk Images are usually downloaded to the Downloads directory and then mounted on the desktop, showing up as a new volume under /Volumes and appearing in the Finder as a disk.
In most cases, applications can be run from any of these locations, leading to the particularly confusing situation of:
Download a disk image
Disk image file goes to the Downloads folder
OS X mounts the disk image
User runs the application just fine from the disk image
User reboots the Mac
Application appears to have disappeared
In this case, the application isn't gone, but the disk image was uncounted by the reboot, and so it isn't obvious to most users where the application has gone.
The most straightforward solution for users is to copy the applications to their Applications folder in order to make sure it is easy to find.
Obscure note: This works well for Disk Images (which can subsequently be deleted), but may cause some confusion for Applications decompressed from zip files if the Application was downloaded on a disk other than the boot volume. I this case, copying the Application may lead to having two copies of it, one in the downloaded location and one in the Applications folder. This can be very confusing if you delete the application as the Finder will still locate it in the Downloads folder. It can also be confusing when you download an update for the application manually, as it may result in multiple copies of the application in your Downloads folder. These will usually be named "My app", "My app 1", "My app 2", etc.

Is it possible to recover encrypted files/folders?

I've found some remnant documents on one of my hard drives that were somehow encrypted (appearing green in Windows 7 Ultimate x64).
I've attempted to uncheck Encryption in their properties, but I get access denied. I've figured this to be because the files were from a previous format/iteration of my desktop setup, and must have somehow inadvertently gotten encrypted. (I now believe it had something to do with transferring them at one point onto a Mac machine/drive, and then back, not realizing that they were encrypted until post-format).
I originally posted in this question that I thought I had a VMware image from the same time period as the files, and that perhaps it'd be possible to transfer the key from that image to my current machine, but that image is not the right one! :/ I don't have an image that goes back further.
I've tried copying the files to a FAT32 USB drive (as it would strip the encryption), but Windows 7 denies that (understandably). And as expected, trying to drag/copy the files from my current machine onto the VMware running machine also gets denied, as VMware is running within Win7's domain and rules.
Any ideas? What about booting my current machine off of a linux live USB stick, and then attempting to copy the NTFS encrypted files onto a FAT32 partition (thus removing the encryption) -- Would that work, seeing as how Windows wouldn't be "awake" to prohibit copying?
I found a zip archive where these files originated from. Whenever I extracted them, however, they'd appear green. Sure enough, there's also a MACOSX folder in the zip file (no idea why Windows decides to encrypt anything that's coming from a Mac).
I was able to copy the zip file onto the old VMware image of mine and extract the zip file there. It still came up as encrypted, but right clicking the folder, clicking properties, and unchecking Encryption fully decrypted the folder and files!
I'd assume that even though this VMware image's machine name was different from the user record within the file's encryption information, it likely was actually the same, originating machine and subsequent encryption certificates.
Anyway, I was able to copy the decrypted files back, and now the problem's solved!

Resources