Wednesday, May 15, 2013 10:39:21 AM
windows defender, mse, windows8
When you are set to receive windows updates manually or just check for them but install on demand you will occasionally get a "Definitions out of date" alert in the security center, and a definition update entry in your Windows Update panel as well as a logon screen nag that you have updates available.
Since you cannot have Defender update itself automatically while auto-install all updates is off, you could click the security center alert and select check for definitions, which would pop-up the defender window and show you the updating progress etc.
With a little procmon tracing it turns out that the security center is calling the following command:
"%programfiles%\MpCmdRun.exe" SignaturesUpdateService -UnmanagedUpdate
which in turn forces a manual update of the definitions if any update is available and most importantly does not open the main defender window or interact with the desktop so you can have it completely automated as a daily scheduled task or a log-on script for example.
Command might need administrative privileges. I could not find this command documented in the command-line switches.
Listing the command-line parameters of MpCmdRun we can see another possibility which is
"%programfiles%\Windows Defender\MpCmdRun.exe" SignatureUpdate
so you might have luck with that one.
Friday, March 16, 2012 1:45:33 PM
windows7
After a couple of improper restarts of my HEADLESS win7 server I got into a stupid position of having an endless repair loop. Since the server (refurbished pc) has no videocard (whatsoever, not even an integrated one) and the only cables sticking out of the back are from the power supply and the gigabit ethernet - all configuration is done after the system boots using RDP.
The problem appears with win7's a built-in boot menu which comes out if you do an improper shutdown/reset/power outage and strangely enough it defaults to the Launch startup repair option instead of Start windows normally one. It's needless to say that choosing that option does not start the normal OS, thus you don't get network access to it.
So after attaching a keyboard and waiting some seconds for the menu to supposedly show itself I had to hit the up arrow and enter key, completely in the dark, judging my success based only on the ping from another host and the server's HDD led.
Thankfully it finally managed to boot into windows...
Annoyed, a net search revealed a forum post by busterh @
sevenforums where he mentions how to make this menu disappear for good.
bcdedit /set {default} bootstatuspolicy ignoreallfailures
If you ever need to turn it back on for some reason use:
bcdedit /set {default} bootstatuspolicy displayallfailures
Make sure to run them as admin in an elevated command window.
Friday, January 27, 2012 6:22:57 PM
opera, newsfeeds, rss, m2
...
Recently a lot of content providers decided to include a lot of unrelated text/graphics/garbage in the upper part of their feeds. In these cases you need to scroll down a ton of stuff just to get to the article link and if you do that often like me, it becomes a chore and annoyance.
Fortunately, because we are using Opera, there are some CSS tricks to alleviate that little problem.
- Navigate to your opera installation folder's styles subdir (most often %programfiles%\Opera\styles)
- Open the feed.css file in any text editor/html editor etc - I recommend notepad2 as it is lightweight and has nice syntax highlighting
- Thanks to Ulrike25's and burnout426's posts we know how to convert the Full Article link to represent the actual full link (optional) by enclosing the following lines with /* comment */ blocks as follows
/* ul.feedEntryAlternateLinks li a { content: -o-language-string(S_NEWSFEED_ALTERNATE_LINKS_HEADER_SINGULAR); } */
/* ul.feedEntryEnclosureLinks li a { content: -o-language-string(S_NEWSFEED_ENCLOSURE_LINKS_HEADER_SINGULAR); } */
Now we get to the placing the link on top part.
First we need to make some space on top where to position the article link unless we want it to cover the feeds body. To do this change the line:
div.feedEntryContent { margin: 1.5em 0 2.5em; } to
div.feedEntryContent { margin: 2.6em 0 2.5em; }Now we can define the style for the link itself. Nothing stops us from using some fancy CSS3 styles to make it stand out a bit. Add this to the feeds.css:
- To position the article link on top:
div.feedEntryLinks ul li a {
position: absolute;
height: 16px;
top: 0;
}
- To increase link font size:
div.feedEntryLinks { font-size: 1.4em !important; }
- To style the link:
div.feedEntryLinks ul li a{
display: inline-block;
padding: 2px 5px 2px 5px;
background: linear-gradient(top, #f8f8f8 0%,#f1f1f1 100%); /* W3C */
background: -o-linear-gradient(top, #f8f8f8 0%,#f1f1f1 100%); /* Opera 11.10+ */
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.46);
border: 2px solid #eaeaea; /* remove line if you don't want a border */
border-radius: 3px 3px 3px 3px; /* rounded corners */
}
Tip: to generate a nice gradient background you can use a css3 Gradient Generator as well as add a drop shadow using this Drop Shadow Generator
- To add a hover effect:
div.feedEntryLinks ul li a:hover {
border-color: orange; /* alternative border color on hover */
background: -o-linear-gradient(top, #ffd65e 0%,#febf04 100%); /* Opera 11.10+ */
}
With the above steps you get something like this:
and when hovered:
From here on you can expand your links even more by making use of advanced
selectors:
div.feedEntryLinks ul li a[href*="download"]{
background: -o-linear-gradient(top, #7d7e7d 0%,#0e0e0e 100%); /* Opera 11.10+ */
}
div.feedEntryLinks ul li a[href*="download"]:hover{
background: -o-linear-gradient(top, #febbbb 0%,#fe9090 45%,#ff5c5c 100%); /* Opera 11.10+ */
}
div.feedEntryLinks ul li a[href*="download"]::before{
content: "";
width: 16px;
height: 16px;
float: left;
margin: 3px 3px 0 0;
background-image: url('download.png');
}
the example above adds a different color background to links containing the string "download" and changes the icon on their left to indicate it. Use image urls relative to the feeds.css.
WARNING: So far opera does not support setting a custom feeds.css in opera:prefs and as such we are editing the original one. This means our changes will:
- require administrative credentials to edit a file in %programfiles%
- affect all users using the opera installation in that folder
- be reverted on every opera update as the installation replaces them
having that in mind be sure to keep a backup of your modified feeds.iniThat's it, hope you find it useful.
Friday, January 27, 2012 12:00:00 PM
ipv4, ipv6, windows, Network
If you're one of those DSL/ADSL users stop reading, this is not for you.
If your ISP is using fiber-optics terminated in LAN switches that connect your homes to the internet, chances are, depending on your subscription type, that you get either 0 (dynamic), 1 (static) more than 1 (static) IP addresses for use.
If you have multiple computers at home and if your case is 0 or 1 you would use some soho router /w wifi and share the Internet connection with it.
The interesting part comes if you have multiple IPs assigned by your ISP to distribute as you see fit.
Each computer is linked to a switch connected directly to the ISP and has its own IP address.
You get some benefits like these among others:
- You are visible on the Internet (able to run a web server, host games and other services)
- You are independent from any other computer on your network
- You are not burdened by hardware limits of soho routers with slow hardware and concurrent connection limits
Now lets say you want to access all your data on your computers that are separate autonomous entities.
One way would be to build an intranetwork, add another NIC to each of them and set a private IP range to be used.
Due to window's inability to identify a network without a gateway/router device on it, using Homegroup in this case is out of the question. Doing the additional cabling is a drag as well so what do we do.
We enable the IpV6 stack on our main NICs we are using for accessing the Internet. We generate an address to form a subnet and as a result we have a local network and internet through the same utp cables. All that is left is to configure advanced file sharing, turn off network discovery, enable password protected sharing, add firewall rules so samba ports, rdp logins etc. are accessible only from out computers and thats it.
When I have more time I might elaborate more on this topic.
Thursday, March 3, 2011 11:34:36 PM
In here I plan to list all the folders around the system that tend to grow under certain conditions. I will also note the ones you can safely delete and the ones you shouldn't touch. Easiest and fastest way to clear a folder ignoring any locked files is to hit Win+R > type
cmd >
rd /q /s "folderpath"%SystemRoot%\WinSxS (C:\Windows\WinSxS)]
-
Safe to delete: NO
-
Consequences: some applications start failing with errors ala "application configuration is incorrect"
-
Description: Allows coexistence of applications requiring different versions of the same shared dlls
-
Grow conditions: Installation of software, third party updates, runtimes etc.
-
How to prevent from growing: Avoid all installers as well as stuff that comes bundled with runtimes
I noticed every game on steam installs it's dependencies on first run after download. Then you get 10 copies of VisualC++ Runtimes in Add-remove programs and windows update wants to update (and restart after that) each one of them. To stop them always delete the redist folders in your steamapps before the first run of the game. If needed install the required redistributables manually.
%SystemRoot%\SoftwareDistribution\Download (C:\Windows\SoftwareDistribution\Download)
-
Safe to delete: YES
-
Description: Downloaded updates remain here after installation
-
Grow conditions: Installing updates and Service Packs using Windows Update
%SystemRoot%\Temp (C:\Windows\Temp)
-
Safe to delete: YES
-
Description: Temporary files used by system account
-
Grow conditions: Internal system operations create temporary files
%Temp% (C:\Users\User\AppData\Local\Temp)
-
Safe to delete: YES
-
Description: Temporary files for user operations
-
Grow conditions: Constantly filled with crap. Used by archivers, setups etc.
%SystemDrive%\ProgramData\Microsoft Visual Studio\10.0\TraceDebugging
-
Safe to delete: YES
-
Description: Visual Studio 2010 Trace Logs
-
Grow conditions: ~20mb files generated on each compile depending on architecture
%SystemRoot%\Installer\$PatchCache$ (C:\Windows\Installer\$PatchCache$)
-
Safe to delete: SOMEWHAT
-
Description: Windows Installer patch cache
-
Grow conditions: Installing and updating programs which use windows installer format keep cache to handle repair installations
-
Side effects: Some installers might ask for original installation media when attempting a repair / update or even uninstall
More to come...
Wednesday, March 2, 2011 11:52:05 PM
OS, windows7, Howto
There are a ton of tutorials on the net that tell you how to mirror or stripe a partition using windows software raid.
Some of them will even guide you on how to MIRROR your Boot and system Partitions after you installed windows.
While most of them agree that it is IMPOSSIBLE, I WILL SHOW YOU HOW TO ACTUALLY INSTALL THE DAMN WINDOWS ON A DYNAMIC HARD DISK FROM THE BOOTABLE WINDOWS 7 DVD, WITHOUT CONVERTING OR REFORMATTING
- No more deleting of partitions and reverting to basic disks.
- No more losing all the data located after the system partition.
- No more paying for commercial useless-ware to convert your dynamic disk back to a basic one.
*APPLIES TO SERVER 2008 AS WELL AS 7Read more...
Friday, October 29, 2010 3:34:51 PM
windows, errors
If
Process Explorer cannot identify and highlight .NET processes and Displays error:
The .NET performance counters on this system are corrupt.
Run Exctrlst from the Microsoft Windows Resource Kit to repair them.
Contrary to the suggested action all you need to do is RegEdit:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\.NETFramework\Performance
Change value of REG_SZ Type "
Library" from
donotload_mscoree.dll to
mscoree.dll<<
OR >>
save this in a .reg file and import it:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\.NETFramework\Performance]
"Library"="mscoree.dll"
Friday, October 29, 2010 3:28:51 PM
windows7, perfmon, resmon
Not all disks or NO disks at all show up in resource monitor (Start > Run > resmon).
Happens occasionally for some unknown reason probably related to SATA drivers / controllers / configuration changes.
SOLUTION:
Start > Run > cmd (as Admin)
lodctr /r
Sunday, October 24, 2010 4:14:55 PM
windows, folder icons, commandline, customization
Frustrated by the lack of any commandline tool to easily change folder icons and the TON of useless shareware gui solutions for this, and even more annoyed by the "professionals" all over the web who suggest manually writing a desktop.ini, I am releasing this one myself as unmanaged c++ vc10 binaries, both x86 and x64.
Source available under GPL.
How others suggest to do it:
- Create a desktop.ini inside the folder
- Add [.ShellClassInfo] / IconFile / IconIndex to it.
- Set folder attributes to system
- Restart explorer.exe / clear icon cache on every icon change to be reflected
The proper way to achieve this:
- Create a SHFOLDERCUSTOMSETTINGS struct
- Modify it's attributes
- Apply the struct to a folder via SHGetSetFolderCustomSettings
- Notify shell the icon has updated via SHUpdateImage
What you gain from this method:
- Icon changes are immediately visible
- No more deleting icon cache
- No more refreshing of global icons to get a single folder to reflect changes
- Works properly in Vista and 7
Syntax:
Set Icon:
IconChanger.exe <dirname> <iconfile> <iconindex>Clear Icon:
IconChanger.exe <dirname>Download windows binaries (includes x86 & x64. Requires
Visual C++ 2010 Runtimes):
http://devocalypse.com/dl/CLI_Icon_Changer_2.10.rar*Currently only works on Vista / 7. Will fix it soon.Full Source code:
http://devocalypse.com/src/source.php?src=iconchanger2.cppIncludes code from:
https://cfx.svn.codeplex.com/svn/Visual%20Studio%202008/CppShellGetSetFolderCustomSettings/Guide to get it to work within a Directory Opus toolbar:
http://resource.dopus.com/viewtopic.php?f=16&t=12670
Sunday, September 19, 2010 1:52:17 PM
windows7, Drivers, Windows Update, annoyances
After breaking my network drivers for my nforce680i I was forced to reinstall them and made a grave error of downloading the latest nforce software from nvidia.com. Ever since I installed those I was getting occasional and random packet drops and bad latency (2500-3500ms) on a gigabit network over perfectly working cat5e cables. After checking all hardware I narrowed it down to be the driver of the nVidia network controller. Since the install of the nVidia software unfortunately i had no driver roll-back option and the last system restore was unreliable and when uninstalling the driver windows just refused to revert to it's stock one included on the Win7 installation dvd. So after searching around and finding nothing, I remembered that there was a driver on windows update which was working perfectly.
So to manually revert to an older driver from windows update do the following:
- Visit http://catalog.update.microsoft.com/v7/ in Internet Explorer 8+
- Install the active-x control when offered to do so
- Search for your driver and specify OS version to get more exact matches
- Click the driver name and see if it matches your processor architecture
- Add the driver to the basket and download it
- Extract the driver cab with winrar or another archiver
- Find your device in "Device Manager"
- Select driver tab > Update driver > Browse my computer... > Let me pick from a list of device drivers..
- Select Have Disk... > Browse to the location you extracted the driver from the update catalog and select the inf
- Agree to overwrite the newer driver and it's done.
Example is for the network driver but should apply to any driver available through windows update.
This saved me from having to choose between a windows reinstall and a constantly unreliable network.
Friday, February 19, 2010 11:22:54 PM
security
Tired of those annoying bots scanning your web server. Here's how to set a trap for them.
Enable mod_rewrite if its not yet enabled in httpd.conf
LoadModule rewrite_module modules/mod_rewrite.so
and allow htaccess overrides to your server root:
AllowOverride All
place a .htaccess in your server root / containing this and/or customize the regex to suit your needs:
RewriteEngine on
RewriteRule ^.*?MyAdmin.* /jackpot.php
RewriteRule ^.*?mysql.* /jackpot.php
RewriteRule ^.*?mail.* /jackpot.php
RewriteRule ^cgi-bin/textenv.pl /jackpot.php
RewriteRule ^vhcs2.* /jackpot.php
RewriteRule ^_vti_inf.html /jackpot.php
RewriteRule ^_vti_pvt /jackpot.php
Order Deny,Allow
Create a jackpot.php containing:
<?php
$ip = $_SERVER['REMOTE_ADDR'];
$line = "\nDeny from $ip" ;
$file = '.htaccess';
$fp = fopen($file, "a");
$write = fputs($fp, $line);
fclose($fp);
?>
Additionally you can create a robots.txt containing this which tells the "GOOD" search bots not to index the blacklister, and the bad bots that ignore it or even access it on purpose get busted.
User-agent: *
Disallow: /cgi-bin/
Disallow: jackpot.php
Disallow: /jackpot.php
Crawl-delay: 10
Thursday, February 18, 2010 6:20:06 PM
opera, customization
Some useful custom function buttons:
Some of the more useful Main Menu dropdown buttons:
Some of the less useful Main Menu dropdown buttons:
Note: Before asking know that these buttons do not work on the latest 10.50 beta although they work if added to the toolbar.ini for which I might post the code later
Thursday, February 18, 2010 4:58:02 PM
opera, customization
Here I will discuss on a way to create your own bookmarklets
Lets assume you have a favorite website example.com to which you want to pass the current page url.
The handler that processes the request on example.com would be /process.php and it would accept a string passed as a "url" argument.
The js code would look like this:
javascript:void(location.href='http://example.com/process.php?url='+location.href)
Now you have two ways of adding it to your browser:1. Add it to your toolbar by editing the ini. Works only in Opera
Button18, "Send URL to example.com"=Go to page, "javascript:void(location.href='http://example.com/process.php?url='+location.href)", 1
2. Add it by dragging a link in a custom html that contains it. Works in all browsers.Note: In opera in order to drag a link to some toolbars you need to hold the SHIFT key while releasing it over the toolbar.
- Create a new text document in notepad or whatever text editor you have
- Paste inside
<html><head></head><body>
<a href="javascript:void(location.href='http://example.com/process.php?url='+location.href)">Send URL to example.com</a>
</body></html>
- Customize the url, handler and whatever you need to.
- Save it as whatever.htm and open it in your browser.
- Output should be something like this:
Send URL to example.com
- Now just drag the link to your toolbar and you're done.
Note: The name of the button will be the text of the link you are dragging so customize it yourself
Thursday, February 18, 2010 4:27:10 PM
opera, toolbar.ini, customization
Heres a nifty way to cycle between multiple proxy servers with radio buttonsNote: Changing a proxy server requires a reload of preferences and as such is affected by the number of tabs you have open. If one tab is open it will be instant. The more tabs you have and windows, the more it will take so patience is keyAdd these lines inside your customized toolbar (\toolbar\standard_toolbar.ini) under a suitable section (for example [Status Toolbar Tail.content])
Checkbox0=Enable referrer logging, , , "R" | Disable referrer logging
Spacer0, , 16
Checkbox1=Enable proxy servers, , , "P" | Disable proxy servers
Spacer1, , 16
RadioButton1="Set preference, "Proxy|HTTP server=192.168.137.1:3138", , "Proxy1""
Spacer2, , 16
RadioButton2="Set preference, "Proxy|HTTP server=192.168.137.1:3148", , "Proxy2""
Spacer3, , 16
RadioButton3="Set preference, "Proxy|HTTP server=192.168.137.1:3158", , "Proxy3""
Spacer4, , 16
RadioButton4="Set preference, "Proxy|HTTP server=192.168.137.1:3168", , "Proxy4""
Spacer5, , 16
RadioButton5="Set preference, "Proxy|HTTP server=192.168.137.1:8118", , "TOR Proxy""
Spacer6, , 16
RadioButton6="Set preference, "Proxy|HTTP server=127.0.0.1:8080", , "MMJava Proxy""
Will result in something like this (except for the names):

Do not forget to specify your own servers and customize your proxy names. I used single letter names in the example. You can adjust and add or remove spacers from within opera.
Thursday, February 18, 2010 2:57:34 PM
annoyances, shell extensions, adobe
If you have adobe acrobat 9 installed but it's context menu entries are in your way:
Windows X86- regsvr32 /u "C:\Program Files\Adobe\Acrobat 9.0\Acrobat Elements\ContextMenu.dll"
Windows X64
- regsvr32 /u "C:\Program Files (x86)\Adobe\Acrobat 9.0\Acrobat Elements\ContextMenu.dll"
- regsvr32 /u "C:\Program Files (x86)\Adobe\Acrobat 9.0\Acrobat Elements\ContextMenu64.dll"
Thursday, February 18, 2010 2:49:21 PM
annoyances, shell extensions, adobe
Nasty Little and above all USELESS thing poisoning your context menu. No more...
- Win X86: regsvr32 /u "C:\Program Files\Common Files\Adobe\Adobe Drive CS4\ADFSMenu.dll"
- Win X64: regsvr32 /u "C:\Program Files (x86)\Common Files\Adobe\Adobe Drive CS4\ADFSMenu.dll"
Thursday, February 18, 2010 2:46:28 PM
shell extensions, annoyances
Here's a quick way to kill the annoying Windows Media Player (insert version here) context menus:
- Win X86: C:\WINDOWS\system32\regsvr32.exe /u wmpshell.dll
- Win X64: C:\WINDOWS\SysWOW64\regsvr32.exe /u wmpshell.dll
Thursday, February 18, 2010 2:30:10 PM
opera, cache directories, firefox, internet explorer
Opera
- Run Opera.
- Navigate to: opera:config
- Set "Cache Directory4" value to "Z:\cacheOpera"
Internet Explorer
- Run IE
-
Tools > Internet Options > General > Browsing History > Settings > Move Folder
- Set to anything you like. Ex: "Z:\cacheIE"
Firefox
- Run ffox
- Navigate to: about:config
- Add item "browser.cache.disk.parent_directory"
- Set it's value to "Z:\cacheFireFox"
Chrome
- Create a shortcut to chrome.exe
- Right click shortcut > properties > target
- Append to target –disk-cache-dir="D:\Some\Folder"
"C:\Users\Someuser\AppData\Local\Google\Chrome\Application\chrome.exe" –disk-cache-dir="D:\Some\Folder"
- Start it everytime from that shortcut
Thursday, February 18, 2010 2:09:29 PM
windows7, shell extensions
This happens if you install a dll / ocx / shell extension with limited user rights OR if UAC is enabled
Solution 1:If you are a power user and administrator, send UAC to HELL and just repeat the DLL registering process
- Start (Win Key) > type uac > ENTER
- Pull slider down to Never notify > OK
- Restart computer.
- regsvr32 "full-path-goes-here"
Solution 2:If you are not ready to let go of UAC
-
Start Menu > Run (or Win+R)
- Type cmd and then Shift+Enter
- Approve running console with administrative privileges.
- regsvr32 "full-path-goes-here"
Thursday, February 18, 2010 1:55:32 PM
shell extensions
If you need to delete a shell extension dll or other program which is already in use by explorer.exe or some other explorer replacement follow these steps:
- Unregister the target shell extension DLL you want to remove:
Start > Run > regsvr32 -u "full_path_to_extension"
- After that to Release the extension you have to reload (restart) all your file managers and all other programs that have a file open / browse dialog and finally the shell itself (Explorer.exe).
TIP: NEVER KILL EXPLORER.exe from task manager. This way it forgets desktop changes from the last reboot. Instead do the following to do a GRACEFUL shutdown of explorer which will leave you with a blank desktop.
On XP:
-
Start > Shut Down (Alt+F4)
- When the Dialog appears hold CTRL+SHIFT on the keyboard and press CANCEL with the LEFT MOUSE
- The shell should terminate shortly after that but your system will still be running
On Windows7 / Vista:
- Open the Start menu
- Hold CTRL+SHIFT and RIGHT-CLICK the transparent start menu area on the RIGHT (just over the shut down button)
- Choose EXIT Explorer
When all is done restart the explorer shell by
- CTRL+SHIFT+ESC (CTRL+ALT+DEL on XP) to bring up Task Manager
- File > Run > explorer.exe
You can now delete the shell extension DLL without errors.
1 2 Next »