Posts

Showing posts with the label Windows

Accessing IOS Safari Web Inspector From Windows Machine

Image
Answer : It appears to require Safari 6, which has not been released for Windows. Regarding the unavailability of Safari 6 on Windows, Apple has stated "Safari 6 is available for Mountain Lion and Lion. Safari 5 continues to be available for Windows." I regularly use weinre . It basically runs a webserver that in turn acts as an inspector-enhanced proxy to browse webpages and websites. The inspector can be started by adding a script to your page or running a bookmarklet. weinre is a debugger for web pages, like FireBug (for FireFox) and Web Inspector (for WebKit-based browsers), except it's designed to work remotely, and in particular, to allow you debug web pages on a mobile device such as a phone. To install it, you will need NodeJS and NPM (included with NodeJS). You will also need a WebKit-based browser on the desktop/receiver end (Safari, Google Chrome, or Chromium). It should work on Windows, OSX, and Linux. Official page: https://people.apache.org/~p...

7-Zip Doesn't Ask Me For A Password For A ZIP File I Encrypted While Double-clicking It

Answer : The ZIP format doesn't allow for encrypting file lists. This means that file lists are viewable by anyone. Only the contents of the files is encrypted, which means that no one can read the file without your password. Due to this, 7-Zip only asks for your password before unzipping. If you need a format that encrypts the file list, use 7Z and make sure you check "Encrypt File Names". For the more technical minded, the ZIP specification doesn't allow for encryption of the Central Directory. You will be prompted for a password when you try to extract the files. To simply view the contents of the archive does not require a password. If you would like to obfuscate the contents of the archive, compress the directory into an archive, and then compress that archive with a password. Thus, you will have to extract the archive with a password, to pull out the archived (and obfuscated) contents. A generalized solution that works for all zip programs (WI...

Best Lightweight Web Server (only Static Content) For Windows

Answer : You can use Python as a quick way to host static content. On Windows, there are many options for running Python, I've personally used CygWin and ActivePython. To use Python as a simple HTTP server just change your working directory to the folder with your static content and type python -m SimpleHTTPServer 8000 , everything in the directory will be available at http:/localhost:8000/ Python 3 To do this with Python, 3.4.1 (and probably other versions of Python 3), use the http.server module: python -m http.server <PORT> # or possibly: python3 -m http.server <PORT> # example: python -m http.server 8080 On Windows: py -m http.server <PORT> Have a look at mongoose: single executable very small memory footprint allows multiple worker threads easy to install as service configurable with a configuration file if required The smallest one I know is lighttpd. Security, speed, compliance, and flexibility -- all of these describe ligh...

Choosing A Windows Automation Scripting Language. AutoIt Vs Autohotkey

Answer : I think AutoHotkey's GUI implementation is easier to use like many of its commands. AutoHotkey (no longer maintained) has 3 forks : AutoHotkey v1.1.* (previously known as AutoHotkey_L) has COM, Unicode support, object-oriented -like syntax, arrays, and more. AutoHotkeyCE works on Windows mobile PDA's and smartphones (unfinished, no longer maintained). IronAHK, a .NET version of AutoHotkey (unfinished, no longer maintained). AutoHotkey includes a DLL file that you can call from other programming languages (so does AutoIt). AutoHotkey is open source, AutoIt is not. You have to search the AutoHotkey site to put all tools together. AutoIt does better at packaging all in its initial download. My vote is for AutoHotkey (AHK). I've used both very much. AutoHotKey is very good at managing hotkeys and basic GUI automation. It's syntax is horrible and it's not meant for bigger applications. AutoIt has almost every feature AutoHotKey has and much ...

200 PORT Command Successful. Consider Using PASV. 425 Failed To Establish Connection

Answer : Try using the passive command before using ls . From FTP client, to check if the FTP server supports passive mode, after login, type quote PASV . Following are connection examples to a vsftpd server with passive mode on and off vsftpd with pasv_enable=NO : # ftp localhost Connected to localhost.localdomain. 220 (vsFTPd 2.3.5) Name (localhost:john): anonymous 331 Please specify the password. Password: 230 Login successful. Remote system type is UNIX. Using binary mode to transfer files. ftp> quote PASV 550 Permission denied. ftp> vsftpd with pasv_enable=YES : # ftp localhost Connected to localhost.localdomain. 220 (vsFTPd 2.3.5) Name (localhost:john): anonymous 331 Please specify the password. Password: 230 Login successful. Remote system type is UNIX. Using binary mode to transfer files. ftp> quote PASV 227 Entering Passive Mode (127,0,0,1,173,104). ftp> You are using the FTP in an active mode. Setting up the FTP in the active mode can be cum...

Best Way To Mirror Folders

Image
Answer : You could take a look at SyncToy from Microsoft. It's got a number options for copying data between folders - this page has a useful guide on it's use and explains what the various options do: Now, you need to choose how you want to backup the information. You can perform the following tasks between two folders: Synchronize : New and updated files are copied both ways. Renames and deletes in one folder is repeated on the other. Echo : New and updated files are copied left to right. Renames and deletes on the left are repeated on the right. Subscribe : Updated files on the right are copied to the left is the file name already exists on the left. Contribute : New and updated files are copied left to right. Renames on the left are repeated on the right. Similar to Echo, except there are no deletions. Combine : New and updated files are copied both ways. Renamed and deleted files are ignored. If these folders are on the same computer, then you can create...

Bridged Vs. NAT: A Virtualbox And VMWare Comparison

Answer : This all looks normal to me. Anything under 10.0.0.0/8 (and also 172.16.0.0/12) are perfectly normal NAT addresses. When you put your VMs in NAT mode, the software is essentially acting as it's own dhcp server for the guest machines and will do translations to the host network, so that all the guests on a particular host share an IP with the host. Anything in any of those ranges are fair game for NAT. It appears that VMWare uses a 192.168.0.0/24 range by default, and VirtualBox uses a 10.0.0.0 range. Both are just fine, and neither is better than the other (though I personally prefer 10.0.0.0 ranges because there are 255 times more addresses available). It sounds like maybe you expected NAT mode to use the NAT between your host network and the internet, but that just doesn't happen. In fact, that is what bridge mode does. Switching to bridged mode means your VM guests are now connected directly to your home router's dhcp server for addresses. VirtualB...

Bash: Npm: Command Not Found?

Answer : Just go into npm page and follow the instructions. If you have already installed nodejs and still getting this error. npm: command not found.. run this apt-get install -y npm I also come here for the same problem, The solution I found is to install npm and then restart the Visual Studio Code

ADB Driver And Windows 8.1

Answer : UPDATE: Post with images ➤ English Version | Versión en Español If Windows fails to enumerate the device which is reported in Device Manager as error code 43 : Install this Compatibility update from Windows. If you already have this update but you get this error, restart your PC (unfortunately, it happened to me, I tried everything until I thought what if I restart...). If the device is listed in Device Manager as Other devices -> Android but reports an error code 28 : Google USB Driver didn't work for me. You could try your corresponding OEM USB Drivers, but in my case my device is not listed there. So, install the latest Samsung drivers: SAMSUNG USB Driver v1.7.23.0 Restart the computer ( very important ) Go to Device Manager, find the Android device, and select Update Driver Software . Select Browse my computer for driver software Select Let me pick from a list of device drivers on my computer Select ADB Interface from the list Select SAMSUN...

Apache Gives Me 403 Access Forbidden When DocumentRoot Points To Two Different Drives

Answer : You did not need Options Indexes FollowSymLinks MultiViews Includes ExecCGI AllowOverride All Order Allow,Deny Allow from all Require all granted the only thing what you need is... Require all granted ...inside the directory section. See Apache 2.4 upgrading side: http://httpd.apache.org/docs/2.4/upgrading.html Somewhere, you need to tell Apache that people are allowed to see contents of this directory. <Directory "F:/bar/public"> Order Allow,Deny Allow from All # Any other directory-specific stuff </Directory> More info For Apache 2.4.2 : I was getting 403: Forbidden continuously when I was trying to access WAMP on my Windows 7 desktop from my iPhone on WiFi. On one blog, I found the solution - add Require all granted after Allow all in the <Directory> section. So this is how my <Directory> section looks like inside <VirtualHost> <Directory "C:/wamp/www"> Options Indexes Follow...

Alternative Console Host For Windows 7/Windows Server 2008

Answer : Below are some nice console-replacements products that are more user-friendly than cmd. As commented below, since Windows 7, all these shells are just an interface to conhost.exe, even powershell. For details, read What is conhost.exe and Why Is It Running. Therefore, the consoles below only replace the default visual interface to conhost which is the one exhibited by cmd, and are only useful when directly invoked as programs. They cannot be indirectly invoked, as when a console-executable such as diskpart is run, since this will invoke conhost, and conhost has its own I/O interface and API. Here is what Microsoft says in Windows 7 / Windows Server 2008 R2: Console Host : ConHost represents a permanent change in the way that console application I/O is handled. There is no registry key or group policy setting that can force Windows to revert back to “legacy mode” console behavior. The conclusion is that if you wish to replace the console in a deeper way t...

Active Directory: Viewing "Attribute Editor" After Finding An Account Via ADUC's "Find" Option

Image
Answer : Solution 1: I'd say set up a query for the user search instead of using the Find feature. It's a few extra clicks, but gives you the Attribute Editor tab properly. Make sure you set the query definition to the "Users..." type instead of the "Common Queries" type, so you get the right search behavior.. ..and the Attribute Editor tab works on the object when opened from this view. Solution 2: This seems to be a solution! http://activedirectoryfaq.com/2014/10/ad-attribute-editor-missing-make-search-visible Open de object after using "Find". Click the "Member of" tab. Open a group of which the object is a member. Close the object window. Locate the object in the group and double-click it. The object window should open with the "Attribute Editor" available. Should work. Tried it myself but I don't have an Attribute Editor available (Attribute Editor does not exist in a 2000/2003 forest). https:/...

C# - How To Get Program Files (x86) On Windows 64 Bit

Answer : The function below will return the x86 Program Files directory in all of these three Windows configurations: 32 bit Windows 32 bit program running on 64 bit Windows 64 bit program running on 64 bit windows   static string ProgramFilesx86() { if( 8 == IntPtr.Size || (!String.IsNullOrEmpty(Environment.GetEnvironmentVariable("PROCESSOR_ARCHITEW6432")))) { return Environment.GetEnvironmentVariable("ProgramFiles(x86)"); } return Environment.GetEnvironmentVariable("ProgramFiles"); } If you're using .NET 4, there is a special folder enumeration ProgramFilesX86: Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) Environment.GetEnvironmentVariable("PROGRAMFILES(X86)") ?? Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles)

Any Difference Between DOMAIN\username And Username@domain.local?

Answer : Solution 1: Assuming you have an Active Directory environment: I believe the backslash format DOMAIN\USERNAME will search domain DOMAIN for a user object whose SAM Account Name is USERNAME. The UPN format username@domain will search the forest for a user object whose User Principle Name is username@domain. Now, normally a user account with a SAM Account Name of USERNAME has a UPN of USERNAME@DOMAIN, so either format should locate the same account, at least provided the AD is fully functional. If there are replication issues or you can't reach a global catalog, the backslash format might work in cases where the UPN format will fail. There may also be (abnormal) conditions under which the reverse applies - perhaps if no domain controllers can be reached for the target domain, for example. However: you can also explicitly configure a user account to have a UPN whose username component is different from the SAM Account Name and whose domain component is differen...

A Simple Explanation Of What Is MinGW

Answer : MinGW is a complete GCC toolchain (including half a dozen frontends, such as C, C++, Ada, Go, and whatnot) for the Windows platform which compiles for and links to the Windows OS component C Runtime Library in msvcrt.dll. Rather it tries to be minimal (hence the name). This means, unlike Cygwin, MinGW does not attempt to offer a complete POSIX layer on top of Windows, but on the other hand it does not require you to link with a special compatibility library. It therefore also does not have any GPL-license implications for the programs you write (notable exception: profiling libraries, but you will not normally distribute those so that does not matter). The newer MinGW-w64 comes with a roughly 99% complete Windows API binding (excluding ATL and such) including x64 support and experimental ARM implementations. You may occasionally find some exotic constant undefined, but for what 99% of the people use 99% of the time, it just works perfectly well. You can also use t...

Are There Alternatives To Sysinternals ADInsight?

Answer : There are known issues with ADInsight and it is no longer supported or developed. It has issues loading its DLL in certain environments, specifically on VMs (see http://forum.sysinternals.com/adinsight-doesnt-work-hangs_topic18891.html and http://forum.sysinternals.com/adinsight-operation_topic18963.html) (archive links) The best solution I have found is to turn on Active Directory Diagnostic Logging as described at http://www.activedir.org/Articles/tabid/54/articleType/ArticleView/articleId/41/Default.aspx (archive link). Basically, you want to set the following registry values: Path: HKLM\SYSTEM\CurrentControlSet\Services\NTDS\Diagnostics\15 Field Engineering Type: DWORD Value: 5 Path: HKLM\SYSTEM\CurrentControlSet\Services\NTDS\Parameters\Expensive Search Results Threshold Type: DWORD Value: 1 These changes do not require a reboot but are set per server, so implementing for an entire forest/domain would best be done via Group Policy Preferences. Once set you will...

7z File Manager Crashed And Left Temp Files Behind

Answer : Using the run command: ( WIN + R ) type "%TEMP%" and hit enter. This will bring up all the temp files stored on your PC through the user account you are on. 7-zip tells you the temp location it uses (extract from 7-zip.org/faq.html): 7-Zip doesn't know folder path of drop target. Only Windows Explorer knows exact drop target. And Windows Explorer needs files (drag source) as decompressed files on disk. So 7-Zip extracts files from archive to temp folder and then 7-Zip notifies Windows Explorer about paths of these temp files. Then Windows Explorer copies these files to drop target folder. To avoid temp file usage, you can use Extract command of 7-Zip or drag-and-drop from 7-Zip to 7-Zip. C:\Users\xxxxx\AppData\Local\Temp under windows 8.1 found MANY 7zipExxxx.tmp folders ...using up 16GB ! reboot did NOT help. Using CCleaner did NOT help. Manually looking at TEMP folders did NOT help. What I did was use WinDirStat to see all m...

Boost::interprocess::named_mutex Vs CreateMutex

Answer : Caveat : I've not spent much time with boost::interprocess , so this information is just from a quick inspection of the source. That said, I've used the Windows synchronisation API's a lot, so here goes... The main difference between the two methods of interprocess synchronisation is how the object exists within the system. With boost::interprocess::named_mutex , as well as a system-specific mutex, it looks like a synchronisation object is created as a file on the system. The location of the file is based on Registry entries (see note 1) (at least in Boost 1.54.0)... it's most likely located under the Common Application Data folder (see note 2). When the aplication crashes, this file is, in your case, not removed. I'm not sure if this is by design... however in the case of an application crash, it's perhaps best not to mess with the file system, just in case . Conversely, when you use CreateMutex , an object is created at the kernel mode...

Batch Character Escaping

Answer : This is adapted with permission of the author from the page Batch files - Escape Characters on Rob van der Woude's Scripting Pages site. TLDR Windows (and DOS) batch file character escaping is complicated: Much like the universe, if anyone ever does fully come to understand Batch then the language will instantly be replaced by an infinitely weirder and more complex version of itself. This has obviously happened at least once before ;) Percent Sign % % can be escaped as %% – "May not always be required [to be escaped] in doublequoted strings, just try" Generally, Use a Caret ^ These characters "may not always be required [to be escaped] in doublequoted strings, but it won't hurt": ^ & < > | Example: echo a ^> b to print a > b on screen ' is "required [to be escaped] only in the FOR /F "subject" (i.e. between the parenthesis), unless backq is used" ` is "required [to be es...

Can I Delete MSOCache?

Answer : Short answer: no . You would most likely no longer be able to perform a repair or install additional components. I have tried it myself on a virtual machine running Windows 7 with Office 2007–I imagine it would have the same effect on Office 2010. A safer option (as suggested here) is to burn the folder itself to DVD or move it to a USB drive, and change all references to it in the Windows registry. From that page: Solution, what I did recently: Burn that whole folder to a CD-R or DVD (the filesize of that folder depends upon your Office version). Delete that folder. Search the registry in RegEdit for C:\MSOCache and change all references to point to your CD/DVD drive, example: E:\MSOCache (will of course require the disc when something Office related needs those cache files.) Way to go would be Junction Point. For example, if you have 120 GB SSD Drive as C: , and 3TB Drive (Magnetic) HDD as D: : on drive D: create sub folder named C cut and paste folder ...