Uncategorized

Why would you use Expression<Func> rather than Func?

Source: http://stackoverflow.com/questions/793571/why-would-you-use-expressionfunct-rather-than-funct   Thấy có bài viết trên stackoverflow về expression, nên add vào blog để lưu 😀 Issue:  I understand lambdas and the Func and Action delegates. But expressions stump me. In what circumstances would you use an Expression<Func<T>> rather than a plain old Func<T>? Ans: When you want to treat lambda expressions as expression… Continue reading Why would you use Expression<Func> rather than Func?

ASP.NET MVC · Uncategorized

Code! MVC 5 App with Facebook, Twitter, LinkedIn and Google OAuth2 Sign-on

Source: https://docs.microsoft.com/en-us/aspnet/mvc/overview/security/create-an-aspnet-mvc-5-app-with-facebook-and-google-oauth2-and-openid-sign-on   Getting Started Start by installing and running Visual Studio Express 2013 for Web or Visual Studio 2013. Install Visual Studio 2013 Update 3 or higher. For help with Dropbox, GitHub, Linkedin, Instagram, buffer, salesforce, STEAM, Stack Exchange, Tripit, twitch, Twitter, Yahoo and more, see this one stop guide.1 Note You must install Visual… Continue reading Code! MVC 5 App with Facebook, Twitter, LinkedIn and Google OAuth2 Sign-on

IT · Uncategorized

Capture Traffic from Another Machine (Any OS)

Set Remote Machine Proxy Settings Start Fiddler on Fiddler server (the machine that will capture the traffic). Click Tools > Fiddler Options. Ensure Allow remote clients to connect is checked. On the other machine, set the proxy settings to the machine name of the Fiddler server at port 8888. Decrypt HTTPS traffic from the Remote… Continue reading Capture Traffic from Another Machine (Any OS)

IT · Linux · Uncategorized

How configure a new Ubuntu installation to accept ssh connections?

sudo apt-get update sudo apt-get install openssh-server sudo ufw allow 22 That’s the very minimum. It allows unlimited failed password attempts on a known port. Direct root-login is disabled (you can still su and sudo once logged in). If your username and password are guessable and the Internet can see the server, somebody will eventually… Continue reading How configure a new Ubuntu installation to accept ssh connections?