WSL and VS-Code

Windows Subsystem for Linux (WSL) is really cool (currently at version 2, or WSL2). It allows use of some of the most popular Linux distributions from within, and alongside, Windows programs. As long as your PC meets the minimum requirements (which really are minimal), installation is trivial. Installation consists of typing “wsl —install” in an elevated command, powershell, or Windows terminal shell. With this approach, Windows installs the default distribution (which is Ubuntu) and then prompts for a username and password. After that, you find yourself in a Linux shell (bash).

I installed and played around with WSL quite a while back, but hadn’t made much use of it. That, however, has recently changed. I (finally) found some computer hacking training (don’t worry, I’m not doing anything nefarious) that both fits with the way I learn and is organized in (what is for me) an approachable way. If you want to learn computer hacking, check out HackTheBox.com. I’d started several other tutorials and trainings over the past couple of years with limited success, but I think HackTheBox is going to be a keeper. More on that in another, future, post.

To digress a bit, I was at first using Kali Linux installed in a Hyper-V virtual machine to do the hands-on exercises at HackTheBox. This worked pretty well, but there were a couple of minor drawbacks: (1) I had to start and stop the VM, which didn’t take long, but did take a bit of extra time (and clicks), and (2) transferring files between the VM and my main PC was less than seamless. Also, copy-and-pasting between the VM and my PC did not seem to work for me (maybe it was me, or maybe it’s not supported), and while that sounds like only a minor inconvenience, it’s something that would be really helpful. The nice part about the VM approach is that I had a full Kali Linux desktop GUI available where I could run a browser, a shell or three, and the Open Source version of VS Code (distinguishing between the Open Source and Microsoft versions will be important later).

Getting back to WSL, I looked and found that Kali Linux was one of the officially supported distributions. I installed it and poked at it for a while, and found that it did not include any (or at least most) of the hacking tools that basically come with Kali (note that I almost always install use the Kali NetInstaller and choose the “large” or “everything” option (I forget exactly how it’s described). A serendipitous search revealed them missing piece: “sudo apt update” followed by “sudo apt install kali-linux-large -y” fixed all the missing tools issues.

Some of the tools that are routinely used in the HackTheBox exercises run in a shell with no problem. Some, however, such as the Firefox browser, require a GUI to use effectively. Not knowing what would happen, but hoping it wouldn’t melt my PC, I opened the WSL Kali terminal, installed, and then ran, Firefox. Much to my delight it popped open a Firefox window – running in Kali – on my Windows desktop.

Encouraged by my success, I started the Open Source version of VS Code from the Kali terminal. It, too, popped open in a new window on my Windows desktop. Let me briefly digress here once again. I had been using Code in my Kali VM to take notes and keep track of relevant information about the HackTheBox exercises. This worked well, but the Open Source version did not seem to have the capability to sync my settings via my GitHub account. Not a deal-breaker, but definitely an annoyance.

With everything working, I decided to try doing the next HackTheBox exercise using Kali on WSL. Everything worked perfectly, and I was able to copy-and-paste between Firefox running on Kali and programs running directly on Windows. Performance was excellent, and I was able to use all of the desktop real estate provide by my 43” monitor with 4k resolution.

And now, finally, the point of this post…

In my VS Code configuration on Windows, I have several extensions installed, including the “Remote Development” extension pack published by Microsoft. I’ve used the tools in that pack to connect to Linux running either in a VM or on a Raspberry Pi and edit files on those remote file systems. One of the tools included – and one which I’d either not noticed or had ignored – provides easy, totally transparent connection to any of the Linux distros running in WSL. Clicking the “Open a Remote Window” button (the green button in the extreme lower left corner once the Remote Dev pack is installed in VS Code) opens a list of currently available distros in WSL. Clicking the name of the desired distro – in my case, Kali-Linux – connects to that file system and runs VS Code as if it was running there natively. Note that it does a little bit of setup on the remote system the first time, but it takes only a few seconds.

I’m probably the last person on the planet to know about this. Why didn’t someone mention it to me?

Recent Site Update(s)

Recent Site Update(s)

It has been some time since I’ve updated this site, although I doubt that anyone would notice. Oh well – this site is mostly interesting to me (and Nancy) anyway.

I recently replaced the old WordPress theme with “WP Bootstrap Starter” by Afterimage Designs, and I also installed their example child theme called, what else, “wp-bootstrap-starter-child,” also provided by Afterimage Designs. I then set about the task of getting the existing menus, posts, and pages to show up in an acceptable manner. After that, I began customizing the child theme with different theme colors and created a new front-page.php to showcase the most recent posts in the top-level categories in reverse chronological order.

While this site is still very much a work in progress, I think it’s coming along nicely.

Blog, blog, blog…

Blog, blog, blog…

The people who know me won’t be surprised that I have several – well, okay, many – domain names registered. I’ll have a good idea for a site, come up with some names, and then check which ones are available. More often than not I’ll actually register one or two of those. And, of course, I usually register the name(s) with all three of the major Top Level Domains (TLDs): .com, .net, and .org.

Most of the domains I’ve registered over the years are just sitting there with no email addresses, no website, and no other “cloud” properties attached. I keep the names because one day, some day, I’ll use them.

Of course, there are a few that I’ve actually used for web sites, mostly blogs. This (slowlanecafe.com (along with .net and .org)) is my original domain name, and, as you can see, it actually has a website. Five of my other domains also have websites. Check them out:

Over the years, I’ve made attempts to write interesting content for all of them, but the results of my good intentions have been short-lived. Recently, I’ve again been trying to write something for each site every week. However, time constraints and other considerations have made me realize that there is just no way I can keep up with all five and do any of them justice.

So, instead of providing mediocre content for all of them, I’ve decided to focus on the ones that I’m passionate about on a weekly basis, write for this one when I have something to write about, and leave the others for future efforts. I can’t promise the content won’t still be mediocre, but I’ll do my best.

So, [drum roll here]… the ones that I’m going to focus on weekly are the web development and coding related sites, Kobayashi Computing and Kobayashi Coding (which are also related to each other), and Neolithia.

Neolithia will by my playground to write, while the Kobayashies will be my lab for web development and coding. With the exception of dev.kobayashicoding.net (which doesn’t have articles per se, and so has no facility for comments), you can read and comment on the content I produce. If you do want to leave a comment, suggestion, or question, you’ll have to register for an account on the site of interest, and I’ll have to approve your account before you can actually post a comment, suggestion, or question.

I wonder if anyone besides me will ever read any of this…

No, and don’t ask again…

We’ve all seen those check boxes on web forms – generally with the “Yes, send me lots of junk email” choice (maybe not in so many words) already checked – that ask if it’s okay to send you occasional emails or start a free trial of the paid version or install [name redacted] Security Scan or change your default browser to something other than the one you just launched. At least one of these that I’ve seen in the not-too-distant past have the option to decline worded thusly: “No, and don’t ask again.”

I think that’s brilliant, and I think that every request in life should have this as a third option (after “yes” and “no”).

The reason I’ve been thinking about this is that I’ve recently (well, over the last 12 to 18 months) been reading some articles on the importance of learning to say “no.” I’ve slowly come to realize that, along with being an Introvert, I also have many of the traits associated with being a Highly Sensitive Person, and a people pleaser (I’ve seen some indications that there may be a link between these two, but I don’t have a citation).

Psychotherapist Kali Munro, in her excellent article on “People Pleasing” says: “It’s painful being a people pleaser. People pleasers are not only very sensitive to other people’s feelings, and often take things personally, but they also rarely focus on themselves. When they do take a moment for themselves, they feel selfish, indulgent, and guilty which is why they are often on the go, rushing to get things done. Because people pleasers accomplish so much and are easy to get along with, they are often the first to be asked to do things – they are vulnerable to be being taken advantage of.”

I don’t know how I came to be this way, and I don’t think the causes cited in the article linked above really apply to me. But I have for many years had a terrible time saying “no” to almost any request from a family member, friend, or co-worker. It may or may not be interesting to note that I have no trouble whatsoever saying “no” to telemarketers, or really to most sales types.

Lately, I’ve been doing better at saying “no” to requests. In fact, my default answer when people ask me to do something has become “no” (it used to be “yes”). I have found that life has been much less stressed when I’m not over-committed to a bunch of tasks that (a) I’m not interested in to start with, and (b) don’t further the goals that I have.

One thing that has made learning to say “no” difficult, is that for so long I agreed to do so much, that now when I do say “no” people will continue to ask – either immediately or over several days to a few weeks – and also try to convince me to do what they want me to do. I don’t want to be rude to people, or to seem unkind, but I guess I’m going to have to learn to say “no, and don’t ask again” in addition to, or maybe instead of, learning to say “no.”