All about Cloud & Powershell

Powershell ile karmasik parolalar uretmek

Powershell’in en iyi yanlarindan biri de bir suru kutuphanenin (.NET libarary) kullanilabilmesidir.

Buna bir ornek verelim istedim bugun. System.Web derlemesini kullanarak minik bir ornek yapalim o halde.

Kompleks bir parola olusturmak icin oncelikle System.Web’i oturum icine ekliyorum. Akabinde de System.Web.Security.Membership’in bir elemani olan GeneratePassword fonksiyonunu cagiriyorum. Iste size kompleks bir parola. GeneratePassword fonksiyonunun 2 parametresi bulunuyor. Ilki toplam karakter uzunlugu digeri ise ozel karakter uzunlugu. Yani; ornegin (20,10) burada icinde 10 adet ozel karakter bulunan toplam 20 karakterli bir parolayi isaret ediyor.

Olusturulan parola henuz SecureString tipinde olmadigi icin parolayi goruntulemek mumkun. Bunu istemeyecegimiz icin hemen veri tipini SecureString yapalim oyleyse.

Yazıyı Paylaş! These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Facebook
  • Google Bookmarks
  • LinkedIn
  • Technorati
  • Twitter
BakiOnur ()

Microsoft Most Valuable Professional (MVP 2009,2010,2011,2012,2013,2014,2015,2016 Current) Towershell.com Founder clouderz.com Founder Microsoft Certified Trainer (10 years in a row, current) Onur has been working in IT arena with more than 15 years of experience specifically in Windows Server, Exchange Server and Powershell and for the past 5 years in Cloud Technologies including Office 365, Azure and so on. He's authored Windows Server books and written more than 400 technical articles published on several communities. Some of his hundreds of Powershell tools and scripts has been published on Microsoft Script Center. Onur is also a 10-year MCT who has delivered more than 10.000 hours of training in Microsoft technologies. He has been to over 70 universities and presented several Microsoft technologies with highlighted topics. He graduated from Okan University Graduate School in Computer Engineering. He lives in London and is currently running his own business at Clouderz Ltd.

Sosyal Medya

Visit Us On TwitterVisit Us On FacebookVisit Us On Linkedin
@BakiOnur 'u Takip Et

MVP Profili

Kategoriler

Arşiv

Soru ve Önerileriniz

[si-contact-form form='1']

Download