Get Windows to Remember Network Share Passwords

We have a Mac FileShare here at work that we use to share designs and comps to a shared folder. Unfortunately, because of the way it was designed it cannot be joined to our local domain.

This means it has its own local account, and every time I reboot a username and password has to be entered to access it.

I wanted to find a way to allow me to access the drive without having to enter a username and password.

After some searching, I found a command line tool built into Windows that will do this:

cmdkey

This will allow you to store multiple username and password combinations for different network resources, while keeping them encrypted in the registry.

So, in my case I have the MAC File share on 10.10.27.231. For sake of example, it’s username is username and its password is password.

To add it to Windows simply type this at the command line:

cmdkey /add:10.10.27.231 /user:username /pass:password

If you wanted to remove it from the cache, you would call it like this:

cmdkey /delete:10.10.27.231

Also, you can get a list of the currently remembered ones like this:

cmdkey /list

If you are stuck on Windows XP, you can find cmdkey.exe on a Windows 2003 server. Just copy it from c:\windows\system32\cmdkey.exe

Simple MD5Sum Generator Used for Warm and Synergy Updater

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Security.Cryptography;
using System.IO;

namespace WarmMD5Sum
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            // Get current application directory path
            string executableName = Application.ExecutablePath;
            FileInfo executableFileInfo = new FileInfo(executableName);
            string executableDirectoryName = executableFileInfo.DirectoryName;

            // Process the list of zip files found in directory where this program is running
            string[] fileEntries = Directory.GetFiles(executableDirectoryName, "*.zip");

            string filesProcessed = "Files Processed:" + Environment.NewLine + Environment.NewLine;

            foreach (string fileName in fileEntries)
            {
                // Generate MD5Sum from file
                byte[] b = System.IO.File.ReadAllBytes(fileName);
                string sum = BitConverter.ToString(new MD5CryptoServiceProvider().ComputeHash(b)).Replace("-", "").ToLower();

                // Create MD5Sum file  
                string MD5SumOutputFile = fileName + ".MD5Sum";
                TextWriter tw = new StreamWriter(MD5SumOutputFile);
                tw.WriteLine(sum);
                tw.Close(); 
               
                // Record what files were processed
                filesProcessed += fileName + Environment.NewLine + Environment.NewLine;
            }

            MessageBox.Show(filesProcessed);

        }
    }
}