Does DNS filtering still work?
DNS, or domain name system is how nice names like google.com get translated into an IP address and eventually find the server that has your content. For this article we are going to focus on website filtering (or content filtering) since the goal is to block access to websites that are deemed inappropriate. This can be blocked by a parent, employer, ISP, or government regulation/policy. Employers typically have an enterprise policy which gets pushed out to your web browser, and they often have a proxy at the edge of the network which does HTTPS inspection.
c++ programming quick tips
c++ is one of my favorite programming languages. It has been around a long time (I used it for my bachelor degree) and is very mature. The libraries and optimized algorithms are great to make software fast and efficient. The downside is more modern languages provide a wide array of features that make development much quicker. One of the main features is garbage collection, which is a memory management technique that Python and many other languages have built-in.
Default route or full routing table?
When a company/enterprise is signing up with an ISP for internet access, they are able to connect in many different ways, but we are going to go over a couple of the popular methods. NOTE: This is a brief overview to answer this one question, BGP is very powerful and programmable, so we won’t touch on most of its features. If the company has its own ASN (Autonomous System Number) they can connect to an ISP and advertise out this number through BGP with the IP space (prefixes) they own.
Some uwsgi settings for Django with StreamingHttpResponse
I have been working with Django quite a bit the last few months, and finally deployed the app into production. The setup uses uwsgi and nginx. My Django app uses threads quite a bit, and when deployed to development server using uwsgi/nginx, it was painfully slow. As in it took 15 minute to run commands that should take 30 seconds. So it took a while of experimenting, and determined that a setting was missing in the uwsgi configuration.
Get the time and date in the future with different timezones in python
I recently had the need to figure out the date and time in my local timezone (Phoenix) for a future appointment. Bookings on a website don’t open until 12:01AM in their local timezone (HST), so how can you determine what date and time that is locally? Don’t want to be late to book! Counting on the calendar can be wrong by a day as well. Python to the rescue. Two libraries make this easy: datetime and pytz.
Cumulus and Netmiko
This post will walk through a quick script that connects to a Cumulus switch and runs a command. Cumulus has a virtual machine appliance called VX available for free to run your tests on. Cumulus VX Much of this can be found on the netmiko github:Netmiko There is an examples directory that goes into more details for adding things like concurrency. If you are running this on 10+ switches in series, things get slow!
Meteor 1.5 and Code Splitting with React and React Router
Meteor 1.5 is out and we can finally do code splitting! If you are not familiar with code splitting, this allows us to separate our logic in a single page web app (SPA) and only send the client the relevant portions of code. This is useful in a couple immediate ways: You have a giant application that is too large to send at once (any script files over 1MB often take too long and the user experience is terrible) You want to keep some portions of code hidden until the user is authorized to see it We are going to cover option 2 since that is a use case I just ran into.
Moving To Containers in Meteor (ES6) For React
The current way to connect Meteor into your React App is to use ES6 based components. Meteor has a function called “createContainer” that will send Meteor data into your React component as props instead of “this.data” access. This can make it a bit more complicated if you need to change your subscriptions based on React’s state, but we will talk about the new pattern you will need to use. This is a better pattern long term as you can switch out the top level data injection and re-use all your display logic (say you want to swap out Meteor down the road, or use Redux).
Re-factoring from React CreateClass to Native ES6 Classes
For the past few weeks I have been refactoring a client’s app to move from the React.CreateClass() format to the new and shiny ES6 class based format. We also re-factored Meteor from a mixin to the new createContainer component format. While we are at it, let’s demonstrate the functional based components for a child that only uses props (so not state). Functional components make the code much cleaner as you don’t need constructors for just display logic.
React in a WordPress page
Connect your Meteor App with MailChimp
Does your application have users? I hope so! Keep them around and active. The best way to get users engaged, and keep them coming back is to use email marketing. You can create a sign-up workflow, move users to different workflows based on what they are doing in your app, and re-engage users that haven’t logged in for X months/weeks. Its very easy, so here is some code that connects to the MailChimp API and lets you add users to Lists.
Meteor, React and Browserify
I have been chasing down an odd issue with a Meteor/React app I am building. The error showing up in the browser console is: You are currently using minified code outside of NODE_ENV === ‘production’. This means that you are running a slower development build of Redux. You can use loose-envify (https://github.com/zertosh/loose-envify) for browserify or DefinePlugin for webpack (http://stackoverflow.com/questions/30030031) to ensure you have the correct code for your production build.