windows-server-2008-r2

Powershell script to find currently bound expiring certificates in IIS

匆匆过客 提交于 2019-12-04 07:56:55
I am trying to get a working script to check for expiring SSL certificates in IIS. There are many similar entries with simply getting the list of expiring installed certificates but I need some extra logic. I need to know all certificates expiring within x days that are A) currently bound to a website and B) that website must have a state of "Started" I have certain information gathered (below) but I am having trouble correlating them so they only give me the expiring certs I need. To add to the complexity, I can't simply look for the site name in the CN in the subject of the certificates

IIS 7.5 not compressing JSON when set in application web.config

半城伤御伤魂 提交于 2019-12-04 07:06:10
I've been working on enabling JSON compression from one of our MVC3 sites. From various articles I've read it seems as though I should be able to set the application/json; charset=utf-8 MIME type in the applications web.config file. But doing so does not enable compression. But when added to the applicationhost.config file, it works. Am I missing something here? My application web.config has the following added to it: <httpCompression directory="%SystemDrive%\inetpub\temp\IIS Temporary Compressed Files"> <scheme name="gzip" dll="%Windir%\system32\inetsrv\gzip.dll" /> <dynamicTypes> <add

Mongodb hotfix KB2731284

廉价感情. 提交于 2019-12-04 04:16:43
问题 I installed MongoDb on a windows server 2008 R2 and the hotfix KB2731284 is not installed, but I cannot restart the server easily. In the hotfix description, I got this message "You run an application that uses the FlushViewOfFile() function to clean up memory-mapped files from the paged memory pool." (see https://support.microsoft.com/en-us/kb/2731284) My question is, when the funtion FlushViewOfFile() is called? My application is just writing in a collection and get data from it. Do I risk

LDAP Search with winldap.h on AD Server

与世无争的帅哥 提交于 2019-12-04 01:46:44
问题 I am trying to do a LDAP search and it is not working on my Active Directory Test Server. I use this code: #include <winldap.h> ... LDAP* ld = ldap_init("AD-servername", 389); int myVersion =LDAP_VERSION3; ldap_set_option(ld, LDAP_OPT_PROTOCOL_VERSION, &myVersion); ldap_connect(ld, NULL); //ldap_simple_bind_s(ld, NULL, NULL); I tried using this line too. but got the same error LDAPMessage *pMsg = NULL; int retVal = ldap_search_s(ld, "dc=myDomain,dc=extension", LDAP_SCOPE_SUBTREE, "

How to write in a registry key own by TrustedInstaller

梦想的初衷 提交于 2019-12-04 00:25:07
In order to install a new property page into the Active Directory SnapIn, I need to write into the following registry key of W2K8 R2 ( as documented by Microsoft ) HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC\SnapIns{E355E538-1C2E-11D0-8C37-00C04FD8FE93}\NodeTypes This key is own by a special user called TrustedInstaller . I found a lots of thing on the NET arround that. At the moment here is the way it works doing the following (user is member of administrator group): I give the user the privilege to take ownership. The user take ownership The user write the registry the user give ownership to

Windows could not start service on Win Server 2008 R2 SP1 (Error 1053)

一笑奈何 提交于 2019-12-04 00:07:41
This issue seems to be widely discussed, but I have problems with finding the solution in my particular case. My service is set up to be running under Local System account. On my first machine with Windows 7 SP1 (64-bit) installed, everything works as expected. But, just after I try to start the service on my second machine with Windows Server 2008 R2 SP1 (64-bit) , not even a second passes, and I'm facing this annoying error: Windows could not start the ProService service on Local Computer Error 1053: The service did not respond to the start or control request in a timely fashion The System

Register DLL file on Windows Server 2008 R2

匆匆过客 提交于 2019-12-03 22:24:12
I'm trying to register a COM DLL file on Windows Server 2008 R2. Here are the steps I took: Run cmd as administrator c:\windows\system32\regsvr32.exe c:\tempdl\temp12.dll When I execute that command I get this error: The module temp12.dll failed to load. Make sure the binary is stored at the specified path or debut it to check for problems with the binary or dependent .DLL files. The specified module could not be found. I was able to register the same DLL file on Windows 2000. I also tried c:\windows\syswow64\regsvr32 "c:\tempdl\temp12.dll" And I got this error: the module c:\tempdl\temp12.dll

Powershell Security Log Get-EventLog

六月ゝ 毕业季﹏ 提交于 2019-12-03 21:42:58
I am trying to write something up in powershell and completely new to powershell, I need help. What I'm trying to do is get information from the Security Log. Specifically, the last login for users over the last two weeks. The code that I have so far is getting login's for the event ID 4624 based on the last 100 events. This is also returning not just users but computers as well. How can I limit the results to just users over a period of two weeks? Is this even possible? $eventList = @() Get-EventLog "Security" -After $Date ` | Where -FilterScript {$_.EventID -eq 4624 -and $_

How to Access Remote USB Smartcard during RDP

旧城冷巷雨未停 提交于 2019-12-03 20:51:18
[My set up] RDP Client (Win7) ------------------RDP------------------------> Remote Server (Win2k8R2) with SmartCard I've found countless answers that would suggest this is not possible. Alot of answers indicate that RDP was designed this way for security. The smartcards are locked which do not allow the device to be seen when connecting remotely with Remote desktop connection (RDP). However I've found a useful link which appears to work for some but not all. http://lifayk.blogspot.co.uk/2012/07/windows-smart-card-subsystem-and-remote.html The guide shows how it's possible (by editing the

PHP Error Logs on IIS 7.5/Windows Server 2008

谁说我不能喝 提交于 2019-12-03 17:11:25
问题 I'm confused about where I should be looking for a log file containing php errors on a Windows 2008 Server running IIS 7.5 (I'm more familiar with the Mac OS X setup for this). In my php.ini file I have log_errors set to "On" but I'm not seeing any php errors in the IIS logs that appear in this folder: C\inetpub\logs\LogFiles Is it possible to have the php errors included in this file or do I need to specify a new file just for php errors? (I'm trying to troubleshoot a site that is generating