Robocze   Leave a comment

 

https://dotnetcodr.com/2016/01/21/using-client-certificates-in-net-part-4-working-with-client-certificates-in-code/

// load certificate var x509 = new X509Certificate2(X509Certificate.CreateFromSignedFile(@”C:\mySignedFile.exe”));

Console.WriteLine(„Certificate is valid: {0}”, x509.Verify());

 

Wklejono z <http://www.csharpdeveloping.net/Snippet/how_to_validate_x509_certificate>

 

 

http://www.bbc.com/future/story/20170612-what-you-can-learn-from-einsteins-quirky-habits

 

===

http://www.infoworld.com/article/3201884/application-development/best-of-nosql-7-document-databases-compared.html?upd=1498249882335

===

//Output chain information of the selected certificate.

X509Chain ch = new X509Chain();

ch.Build (certificate);

Console.WriteLine („Chain Information”);

ch.ChainPolicy.RevocationMode = X509RevocationMode.Online;

Console.WriteLine („Chain revocation flag: {0}”, ch.ChainPolicy.RevocationFlag);

Console.WriteLine („Chain revocation mode: {0}”, ch.ChainPolicy.RevocationMode);

Console.WriteLine („Chain verification flag: {0}”, ch.ChainPolicy.VerificationFlags);

Console.WriteLine („Chain verification time: {0}”, ch.ChainPolicy.VerificationTime);

Console.WriteLine („Chain status length: {0}”, ch.ChainStatus.Length);

Console.WriteLine („Chain application policy count: {0}”, ch.ChainPolicy.ApplicationPolicy.Count);

Console.WriteLine („Chain certificate policy count: {0} {1}”, ch.ChainPolicy.CertificatePolicy.Count, Environment.NewLine);

===

nAJPEŁNIEJSZa informacja – https://blogs.msdn.microsoft.com/alejacma/2011/06/21/how-to-verify-validity-of-certificates-with-net/

===

https://msdn.microsoft.com/pl-pl/library/system.security.cryptography.x509certificates.x509chainstatus(v=vs.110).aspx

=

//Output chain information of the selected certificate.

X509Chain ch = new X509Chain();

ch.Build (certificate);

Console.WriteLine („Chain Information”);

ch.ChainPolicy.RevocationMode = X509RevocationMode.Online;

Console.WriteLine („Chain revocation flag: {0}”, ch.ChainPolicy.RevocationFlag);

Console.WriteLine („Chain revocation mode: {0}”, ch.ChainPolicy.RevocationMode);

Console.WriteLine („Chain verification flag: {0}”, ch.ChainPolicy.VerificationFlags);

Console.WriteLine („Chain verification time: {0}”, ch.ChainPolicy.VerificationTime);

Console.WriteLine („Chain status length: {0}”, ch.ChainStatus.Length);

Console.WriteLine („Chain application policy count: {0}”, ch.ChainPolicy.ApplicationPolicy.Count);

Console.WriteLine („Chain certificate policy count: {0} {1}”, ch.ChainPolicy.CertificatePolicy.Count, Environment.NewLine);

===

https://msdn.microsoft.com/pl-pl/library/system.security.cryptography.x509certificates.x509certificate2.verify(v=vs.110).aspx?f=255&MSPPError=-2147217396

=

using System;

using System.Security.Cryptography;

using System.Security.Permissions;

using System.IO;

using System.Security.Cryptography.X509Certificates;

 

class CertSelect

{

static void Main()

{

X509Store store = new X509Store(„MY”,StoreLocation.CurrentUser);

store.Open(OpenFlags.ReadOnly | OpenFlags.OpenExistingOnly);

 

X509Certificate2Collection collection = (X509Certificate2Collection)store.Certificates;

X509Certificate2Collection fcollection = (X509Certificate2Collection)collection.Find(X509FindType.FindByTimeValid,DateTime.Now,false);

X509Certificate2Collection scollection = X509Certificate2UI.SelectFromCollection(fcollection, „Test Certificate Select”,”Select a certificate from the following list to get information on that certificate”,X509SelectionFlag.MultiSelection);

Console.WriteLine(„Number of certificates: {0}{1}”,scollection.Count,Environment.NewLine);

 

foreach (X509Certificate2 x509 in scollection)

{

try

{

byte[] rawdata = x509.RawData;

Console.WriteLine(„Content Type: {0}{1}”,X509Certificate2.GetCertContentType(rawdata),Environment.NewLine);

Console.WriteLine(„Friendly Name: {0}{1}”,x509.FriendlyName,Environment.NewLine);

Console.WriteLine(„Certificate Verified?: {0}{1}”,x509.Verify(),Environment.NewLine);

Console.WriteLine(„Simple Name: {0}{1}”,x509.GetNameInfo(X509NameType.SimpleName,true),Environment.NewLine);

Console.WriteLine(„Signature Algorithm: {0}{1}”,x509.SignatureAlgorithm.FriendlyName,Environment.NewLine);

Console.WriteLine(„Private Key: {0}{1}”,x509.PrivateKey.ToXmlString(false),Environment.NewLine);

Console.WriteLine(„Public Key: {0}{1}”,x509.PublicKey.Key.ToXmlString(false),Environment.NewLine);

Console.WriteLine(„Certificate Archived?: {0}{1}”,x509.Archived,Environment.NewLine);

Console.WriteLine(„Length of Raw Data: {0}{1}”,x509.RawData.Length,Environment.NewLine);

X509Certificate2UI.DisplayCertificate(x509);

x509.Reset();

}

catch (CryptographicException)

{

Console.WriteLine(„Information could not be written out for this certificate.”);

}

}

store.Close();

}

}

===

https://mva.microsoft.com/en-US/training-courses/creating-bots-in-the-microsoft-bot-framework-using-c-17590?l=ALwJe9kqD_4000115881

https://medium.com/@dailyzen/the-daily-zen-podcast-episode-2-meditation-creativity-c2c0bc8e7df4

Podłącz się dp bazy w VSCode – https://msdn.microsoft.com/magazine/mt809115?MC=Vstudio&MC=SQL

Wstęp do GIT-a – https://msdn.microsoft.com/magazine/mt809117?MC=DevOps&MC=Vstudio&MC=AppDnDTool

Szablon UWP – https://blogs.windows.com/buildingapps/2017/06/22/windows-template-studio-1-1-released/?MC=IoT&MC=MSAzure&MC=MachLearn&MC=Vstudio&MC=GameDev#Tl3WeP0j6ToP3u3S.97

Front-end – https://github.com/grab/front-end-guide?utm_campaign=News%20On%20Monday&utm_source=hs_email&utm_medium=email&utm_content=53562286&_hsenc=p2ANqtz-96sIdXVYKF6-MmW3mxGaRFWvshzezNvpA73oZin7osHoZ4po06qFGsL_Dg27tdcJkmwVcJp-OhJdBcjUs29Rjs5lx1gg&_hsmi=53562286

Od Google – https://developers.google.com/web/tools/starter-kit/?utm_campaign=News%20On%20Monday&utm_source=hs_email&utm_medium=email&utm_content=53562286&_hsenc=p2ANqtz-9pz4JjnYNMCfnmRg0NEip_IVmFifoAfvDjc-LunEKWOVv6Z_XOEzLWzkijjFXFWM6j7Y1zslnruTa51WCL-3cQdZEoig&_hsmi=53562286

Ważne – https://blog.pusher.com/how-to-build-an-android-app-using-cordova-and-vue-js/?utm_source=mobilewebweekly&utm_medium=email

Samouczki MS – https://www.visualstudio.com/pl/vs/getting-started/

Xamarin – ToDo – https://developer.xamarin.com/samples/xamarin-forms/Todo/, git – https://github.com/xamarin/xamarin-forms-samples/tree/master/Todo

Coś w tym jest – https://blog.intercom.com/6-week-cycle-for-product-teams/

Start z X – https://www.intertech.com/Blog/xamarin-tutorial-part-1-create-a-blank-app/?_cldee=bWFyZWsud2F3cnp5bmN6eWtAY29pZy5wbA%3d%3d&recipientid=contact-1d676e4fdc1e443ba1357d422c227d0a-d2b3c4f1e6c34ea6807f8260b6d583fa&esid=1b663ccb-734c-e711-8135-e0071b6a7021

Start z G – http://codecondo.com/get-started-using-git/

Nowa aplikacja Forms – https://forms.office.com/

http://blog.sitedesign.gr/the-week-in-net-on-net-with-brett-morrison-datetime-extensions/

Dokumentacja z WCF /Swagger – https://www.codeproject.com/Tips/1190441/How-to-Generate-Basic-Swagger-yaml-Description-for

Wkład Unity – https://www.codeproject.com/Tips/1190614/Implementing-Unitys-Coroutines-on-Winforms-and-WPF

Ciekawe aplikacje dla SSRS – http://msftrsprodsamples.codeplex.com/wikipage?title=SS2008R2!RSExplorer%20Sample%20Application&referringTitle=Home

Powyższe było z serii – file:///D:/Program%20Files/Microsoft%20SQL%20Server/100/Samples/Reporting%20Services/Application%20Samples/RSExplorer%20Sample/Readme_RSExplorer.htm

Full stack – https://medium.com/coderbyte/a-guide-to-becoming-a-full-stack-developer-in-2017-5c3c08a1600c?imm_mid=0f2736&cmp=em-web-na-na-newsltr_20170607

Z SSRS:

https://docs.microsoft.com/en-us/sql/reporting-services/url-access-ssrs

https://msdn.microsoft.com/en-us/library/ms251671(v=vs.110).aspx

http://msftrsprodsamples.codeplex.com/wikipage?title=SS2008R2!AsynchronousRender%20Sample%20Windows%20Application&referringTitle=Home

 

file:///S:/_Strony_/What%20is%20a%20WebView%20-Telerik%20Developer%20Network.htm

X: http://err2solution.com/2016/05/sqlite-with-xamarin-forms-step-by-step-guide/

Zasoby: https://medium.freecodecamp.org/free-online-courses-cs-programming-june-2017-96a4207bb182

UWP – https://blogs.windows.com/buildingapps/2017/05/25/uwp-evolution-touch-development/#RoUsg5KS1IKoiu1C.97

 

 

===

DataGrid

========

private void dataGridView1_EditingControlShowing(

object sender, DataGridViewEditingControlShowingEventArgs e)

{

ComboBox c = e.Control as ComboBox;

if (c != null) c.DropDownStyle = ComboBoxStyle.DropDown;

}

 

private void dataGridView1_CellValidating(

object sender, DataGridViewCellValidatingEventArgs e)

{

if (e.ColumnIndex == comboBoxColumn.Index)

{

object eFV = e.FormattedValue;

if (!comboBoxColumn.Items.Contains(eFV))

{

comboBoxColumn.Items.Add(eFV);

}

}

}

========

http://www.scribd.com/doc/2461404/DataGridView-FAQ

http://msdn.microsoft.com/en-us/library/7fb61s43.aspx

 

Rodzaje wirtualizacji – http://msdn.microsoft.com/en-us/library/dd430340.aspx#AppendixB z

http://www.msigeek.com/3695/download-video-and-ebook-overview-of-cloud-computing

==============================================================================================

//SSL Certificate code

public enum CertificateProblem : long { CertEXPIRED = 0x800B0101, CertVALIDITYPERIODNESTING = 0x800B0102, CertROLE = 0x800B0103, CertPATHLENCONST = 0x800B0104, CertCRITICAL = 0x800B0105, CertPURPOSE = 0x800B0106, CertISSUERCHAINING = 0x800B0107, CertMALFORMED = 0x800B0108, CertUNTRUSTEDROOT = 0x800B0109, CertCHAINING = 0x800B010A, CertREVOKED = 0x800B010C, CertUNTRUSTEDTESTROOT = 0x800B010D, CertREVOCATION_FAILURE = 0x800B010E, CertCN_NO_MATCH = 0x800B010F, CertWRONG_USAGE = 0x800B0110, CertUNTRUSTEDCA = 0x800B0112 }

public class TrustAllCertificatePolicy : ICertificatePolicy {

// Default policy for certificate validation.

public static bool DefaultValidate = false; // set to true for testing

public bool CheckValidationResult(ServicePoint sp, X509Certificate cert, WebRequest request, int problem)

{

bool ValidationResult=false;

Console.WriteLine(„Certificate Problem with accessing ” + request.RequestUri); // Console.Write(„Problem code 0x{0:X8},”,(int)problem);

//Syslog send-

Sender.Send( GetProblemMessage((CertificateProblem)problem));

ValidationResult = DefaultValidate;

return ValidationResult;

}

private String GetProblemMessage(CertificateProblem Problem)

{

String ProblemMessage = „”;

CertificateProblem problemList = new CertificateProblem();

String ProblemCodeName = Enum.GetName(problemList.GetType(),Problem);

if(ProblemCodeName != null)

ProblemMessage = ProblemMessage + „-Certificateproblem:” + ProblemCodeName;

else

ProblemMessage = „Unknown Certificate Problem”;

return ProblemMessage;

}

}

 

MyWebServiceProxy myWebServiceProxy = new MyWebServiceProxy();

// set a default CertificatePolicy that accepts ALL Server certificates?.

System.Net.ServicePointManager.CertificatePolicy = new TrustAllCertificatePolicy();

myWebServiceProxy.MyMethod(myparam1,myparam2) ;

 

MyWebServiceProxy myWebServiceProxy = new MyWebServiceProxy();

myWebServiceProxy.Url =this.endpointUrl;

//items from your appConfig

NetworkCredential netCredential = new NetworkCredential(this.endpointUserName,this.endpointPassword );

Uri uri = new Uri(this.endpointUrl);

ICredentials credentials = netCredential.GetCredential(uri, „Basic”);

myWebServiceProxy.Credentials = credentials; // Be sure to set PreAuthenticate to true or else authentication will not be sent.

mMyWebServiceProxy.PreAuthenticate = true;

 

MyWebServiceProxy myWebServiceProxy = new MyWebServiceProxy(); // set a default CertificatePolicy that accepts ALL Server certificates

System.Net.ServicePointManager.CertificatePolicy = new TrustAllCertificatePolicy();

myWebServiceProxy.Url =this.endpointUrl; //items from your appConfig

NetworkCredential netCredential = new NetworkCredential(this.endpointUserName,this.endpointPassword );

Uri uri = new Uri(this.endpointUrl);

ICredentials credentials = netCredential.GetCredential(uri, „Basic”);

myWebServiceProxy.Credentials = credentials; // Be sure to set PreAuthenticate to true or else authentication will not be sent.

myWebServiceProxy.PreAuthenticate = true; myWebServiceProxy.MyMethod(myparam1,myparam2) ;

==============================================================================================

 

Masaż lewa dłon prawe palce:

============================

kciuk – lęk, zmartwienie

wskaz – strach

środkowy – gniew, obraza

SERDECZNY – SMUTEK, NIEZDECYDOWANIE

MALY – pewność, szacunek dla siebie

===

Lewy kciuk – 1-2 min naciska na środek wnętrza prawej dłoni

Advertisements

Posted 3 lipca 2017 by marekwmsdn in Bez kategorii

Skomentuj

Wprowadź swoje dane lub kliknij jedną z tych ikon, aby się zalogować:

Logo WordPress.com

Komentujesz korzystając z konta WordPress.com. Log Out / Zmień )

Zdjęcie z Twittera

Komentujesz korzystając z konta Twitter. Log Out / Zmień )

Facebook photo

Komentujesz korzystając z konta Facebook. Log Out / Zmień )

Google+ photo

Komentujesz korzystając z konta Google+. Log Out / Zmień )

Connecting to %s

%d blogerów lubi to: