Skip to main content

Posts

Use Powershell to Read daily news or get Live Sports updates

Hey guys, today we are going to learn how to get news updates using Powershell. For this we will be using API's provided by newsapi.org  . Through this method we can get news update from CNN, Times of India, ESPN, TechCrunch, The Huffington Post and much more. Steps : 1. Open the url  newsapi.org 2. In order to get you own API key you will need to register on the website, to do so click on "Get API Key" present in the Homepage and register. 3. Once you have registered , you will get an API key, don't share the same with anyone. 4. Next, visit  https://newsapi.org/sources  and select the source from where you want to get the news update. We choose "Times of India" 5. Once done, switch to Powershell ISE , and input the below commands : 6. Save it and Execute, you will get the news update instantly. Further this can used to get LIVE Scores and much more. Hope you all liked it. Do share and Comment if any queries.

How-To Surf anonymously using a Proxy browser

Hey all, Previously if you have gone through my blogs, you might have come across several ways to browse anonymous, today we are going to learn the fastest way to do so using a proxy browser. Most often i use this to fetch data which are blocked by my office web protection or any enterprise url blocker like Sophos etc. so lets begin : Step 1: Open the website -- Hide.me Step 2: Type the website name you wanted to surf anonymously Step 3: The best part is that you can even Encrypt the complete page, so give a try Note : This website helps you to access blocked content in the best possible way, although for complete anonymity you should use TOR.

How Invoke-Command works

To know how Invoke-Command works remotely check the below image : Apart from this, lets talk more about Invoke-Command. If you run invoke-command locally will this DeSerialization, conversion to XML etc will happen? the answer is NO. Since you are running it locally all this process are not performed. Further a Deserialized object Type i.e. the data fetched remotely through invoke-command contains only few methods as shown in the below image. Hence suppose you are fetching service info using invoke-command remotely and storing the output in a variable, you won’t get methods to Start or Stop the service. Example : $Service = Invoke-Command -Cn “Test” -ScriptBlock {get-service bits} $Service will show the process details, but you can’t perfom $Service.Stop() or $Service.Start() since its the deserialized data. But you can perform like this : $Service = Invoke-Command -Cn “Test” -ScriptBlock {get-service bits | Stop-Service} This will do the task you are lo

Simplest way to create a log file with Date and Time using PERL

Hi, today em gonna show the simplest way to create log files and add date and time to it so that we can know which event occurred at what point of time. So lets begin. Fetching and Storing Date and Time : use POSIX qw(strftime); my $now = strftime(‘%d-%m-%Y %H:%M:%S’,localtime); Creating Log File : open ($Log,”+>>”,”/home/amar/MyApplication.log”); Printing contents to Log File : print $Log (“$now ******[START OF SCRIPT : DATABASE CHECK]*******\n”); Full Script : This is the simplest way to create a Logger file in Perl. Hope you all enjoyed the post. Do like and Share for more.

JBPM Time Scheduler Format Explained

Hey Friends, Today am gonna explain you the time format used by JBPM Schuduler. Those who don’t know what JBPM is, its basically a Open Source workflow engine used to execute Business Process. For more details read here : JBPM Wikipedia After lots and lots of googling i got the timer info, hence i am sharing the same below : JBPM SCHEDULER SEQUENCE :  Sec Min  Hour  Day of the Month Month Day of the Week Year So suppose, you wanted to trigger process by : Example 1 : 2 AM Sunday Daily Timer : SEC MIN HOUR [DAY OF MONTH] MONTH [DAY OF WEEK] YEAR 0 0 2 ? * SUN * Here, ? mean you don’t know the exact Day of the Month, so JBPM will automatically find it for you just need to put ? , while * is for all , here in the example it means the process should be triggered in all the Months of a year. Example 2 : 4:25 PM All days of a week Timer : 0 25 16 * * ? Lets increase the complexity, suppose you wanted to execute a script every 2 hours in a day then

Windows Services Startup Type Explained

Hi Geeks, Today I was working on a Service related script so thought of sharing some useful information related to Services Startup Type which most of the people knows but doesn’t know about the functionality. So lets begin. What are Windows Services and what they do ? Windows Services are the components or applications that starts when your computer is booted up and runs in the background mode helping the application to work smoothly and finally stops when the computer shuts down. For Example, If you want to send or receive any Fax, then the Fax service should be running in the background to perform the Fax activity. How many Service Startup Types are there and what they do ? There are 4 Service Startup Types available : 1. Automatic Explanation : Automatic Service Startup Type starts the service automatically when the system boot up is done. So if we are having a machine of less memory and there are lots of services in Automatic Startup type then your mac

How to close a Process run by a specific User using PowerShell

Hi Geeks, Today we are going to learn how to close or kill a process run by a specific user. Lets take an example, there are 2 different users : Admin and TestUser , Now Admin and TestUser both are logged into the same machine and performing some important task in Internet Explorer. If Admin does this : Get-Process -Name “iexplorer” It will get all the list of Internet Explorer process run by both Admin as well as TestUser. Now Admin wants to Kill or Stop the Processes which are being executed by him only. So in order to perform this task you can to use the GETOWNER Method. Full Script : Hope you all enjoyed the post, Do Like , Share and comment if you have any query related to this.