arşiv

0, 2017 için arşiv

IP Adres Bulma

Salı, 29 Ağu 2017 yorum yok
public string IP()
{
  string ip = ""
  if (HttpContext.Current.Request.ServerVariables["HTTP_X_FORWARDED_FOR"] != null)
  {
      ip = HttpContext.Current.Request.ServerVariables["HTTP_X_FORWARDED_FOR"];
      if (!string.IsNullOrEmpty(ip))
      {
          string[] ipRange = ip.Split(",".ToCharArray());
          ip = ipRange[0];
      }
  }
  if (string.IsNullOrEmpty(ip))
      if (HttpContext.Current.Request.ServerVariables["REMOTE_ADDR"] != null)
          ip = HttpContext.Current.Request.ServerVariables["REMOTE_ADDR"].ToString();
  ip = ip.Trim();
  return ip;
}

 

Categories: C# Tags:

Get password for IIS Application Pool account

Salı, 22 Ağu 2017 yorum yok

APPCMD:

appcmd is an IIS tool used to manage IIS server. It provides many functions that can be used to manager server related activities like create/configure sites, start/recycle/stop app pools, etc.

Retrieve Password of an App Pool identity account:

  1. To retrieve password for an app pool identity account, open the command prompt in administrative mode.
  2. Navigate to C:\Windows\System32\inetsrv directory. This is the location where appcmd.exe exists.
  3. Type the below command and press enter.
    appcmd.exe list apppool <<app_pool_name>> /text:*
    For example: I have an app pool in my IIS named SampleAppPool which has been assigned a particular account’s identity whose password I would like to retrieve. So I would enter the below command in command prompt.

    cmd

  4. Press enter and the result will be as shown below. Due to security reasons, I have removed the username and password from the image but trust me, it shows the username and password there.result

Referance: https://amoghnatu.net/2015/01/15/get-password-for-iis-application-pool-account/

Categories: Asp.NET, IIS Tags: ,

Yazdığınız script’i kaydetmeden sildiniz mi?

Pazartesi, 21 Ağu 2017 yorum yok

Yazdığınız script’i kaydetmeden sildiniz mi?
Management strudio’nu hata verip kapandı ve satırlarca sql’inizi recover edemiyor musunuz?
Temp dosyalarda bulamadınız mı?

Script’inizi bir defa çalıştırdıysanız üzülmeyin, hala kurtarabilirsiniz smiley
Nasıl mı?

Şöyle;

use [DBName]
go

select	execquery.last_execution_time as [Date Time], execsql.text as [Script] 
from	sys.dm_exec_query_stats as execquery
			CROSS APPLY sys.dm_exec_sql_text(execquery.sql_handle) AS execsql
where	convert(date,execquery.last_execution_time)='20170808'
order by execquery.last_execution_time

 

Categories: SQL Hakkında Tags: ,

Veritabanı Bilgi Havuzu

Salı, 01 Ağu 2017 yorum yok

Tüm veri tabanları hakkında başvuru kaynağı için kullanılır.

http://www.veritabani.gen.tr/

Categories: bestURL, SQL Hakkında Tags: ,