Future of WordPress Platform

While restoring my old blog post, I started thinking about WordPress as a platform. WYSIWYG web site creation services like Wix, Weebly, Squarespace and others are gaining attention and growing fast but they are more services than platforms. WordPress on the other hand has an immense collection of plugins and healthy community of developers and designers behind it.

Main problem I see with WordPress as a platform is that its plugins run on the server-side, creating a compelling long-term incentive to host your own WordPress server to take advantage of features offered by those plugins instead of using WordPress.com. Allowing user-chosen plugins to be installed on WordPress.com creates a gaping security risk and management headaches.

16189100439_84d30fe08f_m.jpg

I think the answer lay with WordPress.com desktop app which currently doesn’t do much beyond what browser version offers and seemingly neglected. Key idea is to add client-side plugins support to the app, plugins that leverage WP REST-API to add features to WordPress-based websites.

There could be several types of client-side WordPress plugins:

  • Interfaces – WYSIWYG editors, media libraries, assistants, etc
  • Generators – generates and updates static assets to be added to the website or injected into webpages.
  • Augmenters – marks, corrects, suggests, and injects.
  • Monitors – tracks changes and stats.
  • Mediators – monitors, controls, and routes posts, comments, transactions, etc.
  • Services – client-side workers
  • Bridges – integrates with third-party services and platforms

And adding Docker support will allow servers to run in client-side sandboxes for use by the desktop.

Result would be a host-neutral platform, one that can address needs of both WordPress.com sites as well as self-hosted sites although it will significantly reduce the need to host your own.

Advertisements

What is JWT?

This post explains what JWT is, without getting into technical details you don’t need to know. Intention of the post is to dispel some harmful misconceptions.

In short, JWT is just a piece of data signed by someone. It doesn’t do much as-is but it’s a key building block useful in many applications.

What JWT Looks Like

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOnRydWV9.TJVA95OrM7E2cBab30RMHrHDcEfxjoYZgeFONFh7HgQ

If you look carefully, it’s basically three gibberish text separated by a period. Th role each part plays are:

Header.Payload.Signature

They look gibberish because they are encoded. Important part is the payload. Rest is there to describe (header) and protect (signature) the payload.

What Each Part Does

Header primarily describes (using JSON) how the Payload was signed so the Signature can be verified.

{
 "alg": "HS256",
 "typ": "JWT"
}

Payload is a collection of name-value pairs presented as JSON like this:

{
  "sub": "1234567890",
  "name": "John Doe",
  "admin": true
}

Signature protects both the Header and the Payload so that neither can be changed without detection.

Key Points About JWT

  • JWT doesn’t say anything meaningful about its sender, recipient nor signer as-is.
  • JWT is not encrypted as-is.

This is not to say JWT can’t but they have to be added. Allow me to go into a bit more detail on each points.

JWT doesn’t say anything meaningful about its sender, recipient nor signer as-is.

JWT typically includes some info on its signer so the signature can be verified but that only proves it was signed by someone who can prove they signed it. Unless the signer is known that is. How one know calls for relationship and/or infrastructure.

Same goes for sender and recipient. To verify sender or recipient, more has to be built-on top of JWT.

JWT is not encrypted as-is.

JWT is typically sent unencrypted over a secure channel of communication to a recipient but it may even be printed plainly using QR-code in newspapers. If you need to protect the token, encrypt it whole in  way that only the recipient can decrypt it. If only part of the payload needs to be protected, then encrypt just the value.


Follow up series of posts will discuss how to build with JWT to solve some common problems like protecting APIs or delegated authorization in a mobile app without issues OAuth has. Stay tuned.

Old Blog Posts Restored

As Monthly Archive links in the left-side bar shows, I uploaded old blog posts last night. Restoration wasn’t perfect of course.

  • Posts from between late 2005 to 2007 is missing. If they are not among backups, I’m going to extract them from Internet Archive.
  • Comments weren’t uploaded. Still on my todo list.
  • Permalinks weren’t restored so links coming in will 404 until they’re fixed.
  • Deadlinks, missing stories and downloads.
  • Category extractor had a separator bug, creating nutty categories like general;technical(fixed now).

Continue reading “Old Blog Posts Restored”

Processing Old Posts

Spent a couple of hours converting my old posts from XML with custom schema to JSON. Scrubbed some obvious spam comments (any comment with more than 5 hyperlinks).

Result is a 7MB JSON file containing 1756 blog posts with comments. Hash of IP addresses were not archived so they’ll all be treated as self-proclaimed foobars.

Next step is to POST them as well as assets they reference to WordPress.com via REST API which should take another couple of hours of hacking since I haven’t bothered to convert the posts to RSS.

Need A Good Theme

This blog goes way back, all the way to 2001. First 7 years of it was the most hectic but they’re archived and need to be restored.

Fresh start calls for a fresh theme. Something that’s simple yet easy to read. No gray text. I may just bang one out from scratch but would rather start with a good one like t his Rewritten Hemingway theme then tweak (post titles looks tad too big and too dark).

Update: That theme lasted only 5 min of staring at it. Let’s try Independent Publisher theme.

Blog Name Change

I’m preparing myself mentally to return to blogging, at a slower pace. To that end, I’ve renamed this blog to Weekly Habit. Blogging daily was exciting back then. I still want to but am wary of blogging for the sake of blogging.

Anyway, stay tuned.