Showing posts with label Alpine. Show all posts
Showing posts with label Alpine. Show all posts

Saturday, July 12, 2014

5.5 amd64 X200: Alpine S/MIME, finally managed to sign with CACert.

Hi,

I finally managed to get my Alpine to sign outgoing emails with Digital Certs from CACert.org, "community-driven Certificate Authority that issues certificates to the public at large for free."

If you're using Thunderbird, setting up Digital Signature is quite easy, just a matter of getting your personal Digital ID and importing it in Thunderbird. There's a few steps in detail but it's just a matter of a bit of adventure in the Thunderbird's Option window.

But if you're like me, who uses Alpine and would like to have the ability to sign with Digital Signature, there's quite a challenge. I've been stuck with this for some time, but as it's not a super-urgent thing, I took my time to solve this. So here I'm posting the steps needed to get my Alpine to sign my email with Digital Cert attained from CACert.org.

1) Register with CACert.org and create a personal Digital Cert.
This step is self-explanatory, go to http://www.cacert.org, register your own account and create your personal Digital Certificate. I don't want to pay for Digital Certificate offered by more trustworthy company so this is a great option for me.

2) Download the Digital Certificate from CACert.org and import in Firefox.
Ok for this, you will need to have Firefox. After you downloaded your Digital Certificate, you will need to open up Firefox, and in Edit > Preferences > Advanced > Certificates > View Certificates > Your Certificates, click on the Import button and import your Digital Cert.

3) Backup Digital Cert from Firefox in PKCS12 format.
From Edit > Preferences > Advanced > Certificates > View Certificates > Your Certificates, choose the Digital Cert you want to use and then click the Backup button. You will need to create a password for it. Remember to save it at pkcs12 format. For example, save it as karl@mail.com.p12.

4) Create PEM format from the PKCS12 file.
Open your xterm, and create a PEM file from the PKCS12 (*.p12) file you just backed up.

$ openssl pkcs12 -in karl@mail.com.p12 -out karl.@mail.com.pem

Now the newly created karl@mail.com.pem file can be edited with vi or any text editor you use.

5) Create CRT and KEY file for Alpine use.
Some people suggested to use openssl to create CRT and KEY file. I didn't managed to do this successfully using the openssl method, and the result is that my Alpine gave out "Couldn't find the certificate needed to sign." prompt when I try to sign my outgoing emails. So I went with the manual way.

Remember that the PEM format is plain text and editable? So I vi the karl@mail.com.pem file. I can see there's 3 section there. The top part is something like this:

Bag Attributes
    *snipped*
-----BEGIN ENCRYPTED PRIVATE KEY-----
*blablabla*

That top portion is the private key. Delete everything before the:

-----BEGIN ENCRYPTED PRIVATE KEY-----

and delete everything after the:

-----END ENCRYPTED PRIVATE KEY-----

then save it to something as karl@mail.com.key. Remember, this is your private key. And don't overwrite the original file you've edited.

Open the karl@mail.com.pem file again. You would see the just below the private key portion, there's something like:

Bag Attributes
    friendlyName: CAcert.org Class 1 Certification Authority
    *snipped*
-----BEGIN CERTIFICATE-----

Now this is you Certificate Issuer portion. I edited the file and deleted everything before the immediate:

-----BEGIN CERTIFICATE-----

and deleted everything after the immediate:

-----END CERTIFICATE-----

then save the file as cacert.org.crt. Do take note that this file could be named as anything but make sure the filename ends with ".crt".

Open the PEM file again, and the 3rd portion is you public key. The "Bag Attributes" details should contain your email address you created the Digital Cert with. So I deleted everything before the:

-----BEGIN CERTIFICATE-----

then save the file to something as karl@mail.com.crt.

6) Setup Alpine to use the karl@mail.com.key Digital Cert.
By default, Alpine needs ~/.alpine-smime directory to store the Digital Certs. But in my case, it didn't exits. So I mkdir these directories:

~/.alpine-smime/ca
~/.alpine-smime/public
~/.alpine-smime/private

Then move all your *crt & *.key files to the correct directory such as:

~/.alpine-smime/ca/cacert.org.crt
~/.alpine-smime/public/karl@mail.com.crt
~/.alpine-smime/private/karl@mail.com.key

That should be it. In Alpine, I use Roles so the From address is the same as my Digital Cert so Alpine can Digitally sign the email composed. So far signing email is ok but I haven't tested the encryption. Later.

References.
- http://www.cacert.org
- http://comments.gmane.org/gmane.mail.alpine.info/4969
- Roles in Alpine
- Alpine S/MIME - http://patches.freeiz.com/alpine/alpine-info/misc/smime.html

Tuesday, March 20, 2012

5.1 amd64 K43U: Alpine > UW-IMAP > OfflineIMAP > Davmail > OWA stuck.

1) Install Alpine+ldap, setting up DavMail.

Install Alpine using port with FLAVOR set to ldap. I just referred to my previous post. So this post will focus more on OfflineIMAP and UW-IMAPd side of the project.

1) Install imap-uw2007

read the /usr/local/share/doc/pkg_readmes/uw-imap-2007f and follow the instruction. For me, I vim /etc/inetd.conf and add:

imap stream tcp nowait root /usr/local/libexec/imapd imapd
imap stream tcp6 nowait root /usr/local/libexec/imapd imapd


And it's also stated a way to enable plain text login. So I vim /etc/c-client.cf and change:

#set disable-plaintext nil

to

set disable-plaintext nil

You can restart inetd, but I just reboot. Then I telnet to localhost:143.

Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK [CAPABILITY IMAP4REV1 I18NLEVEL=1 LITERAL+ SASL-IR LOGIN-REFERRALS STARTTLS] localhost IMAP4rev1 2007f.404 at Tue, 20 Mar 2012 13:27:16 +0800 (MYT)


So far so good. In Alpine I just need to Add Folder collection (S+L+A) with the details:

Nickname: UW-IMAPd
Server: localhost:143
Path: mail/MyCompany/INBOX/
View:


Then after I saved the settings, inside folder list (L) Alpine will ask for my username (same as my OpenBSD's login name) and password (also same as my OpenBSD's password) then I can manipulate my IMAP's INBOX folder. I can add folders, delete etc. So this part is ok.

3) Installing and configuring OfflineIMAP.

I installed OfflineIMAP from OpenBSD's packages. Then I create ~/.offlineimaprc and put the basic as stated in offlineimap.org.

[general]
accounts = MyCompany

[Account MyCompany]
localrepository = Local
remoterepository = Remote

[Repository Local]
type = IMAP
remotehost = localhost
remoteport = 143
remoteuser = karl

[Repository Remote]
type = IMAP
remotehost = locahost
remoteport = 1143
remoteuser = ASIA\karl


Then I run OfflineIMAP by issuing offlineimap. Lo and behold, I got this error:

$ offlineimap
OfflineIMAP 6.3.4
Copyright 2002-2011 John Goerzen & contributors.
Licensed under the GNU GPL v2+ (v2 or any later version).

Account sync MyCompany:
***** Processing account MyCompany
Copying folder structure from IMAP to MappedIMAP
Establishing connection to localhost:1143.
WARNING: Error occured attempting to sync account 'MyCompany':
Traceback (most recent call last):
File "/usr/local/lib/python2.7/site-packages/offlineimap/accounts.py", line 177, in syncrunner self.sync()
File "/usr/local/lib/python2.7/site-packages/offlineimap/accounts.py", line 235, in sync remoterepos.syncfoldersto(localrepos, [statusrepos])
File "/usr/local/lib/python2.7/site-packages/offlineimap/repository/Base.py", line 124, in syncfoldersto srcfolders = src.getfolders()
File "/usr/local/lib/python2.7/site-packages/offlineimap/repository/IMAP.py", line 303, in getfolders self.accountname, self))
File "/usr/local/lib/python2.7/site-packages/offlineimap/folder/IMAP.py", line 32, in __init__ self.name = imaputil.dequote(name)
File "/usr/local/lib/python2.7/site-packages/offlineimap/imaputil.py", line 36, in dequote if not (string[0] == '"' and string[-1] == '"'): IndexError: string index out of range

***** Finished processing account MyCompany


Eh. Bah. Something is wrong somewhere. Help....

Sunday, March 18, 2012

5.1 amd64 K43U: Alpine reloaded, but snapshot has been updated.

Heyya,

I was trying to install Alpine this evening but aspell dependency is giving out error like something have changed. Then I checked my fav snapshot site and found that it's updated since 15th March.

So I'll be updating the snapshot tomorrow.

What's with Alpine again? Well previously I mentioned about trying to make Alpine to be offline email client (Alpine+UW-IMAPD+DavMail+OfflineIMAP) but the adventure never took off. So I'm visiting the trail again. Heh.

p/s: Not to mention that the Alpine+DavMail+OWA post have the most comment by readers. So it might be a useful post to some people. Later

Wednesday, November 24, 2010

OpenBSD NC4200: Getting Alpine to work with DavMail.

Firstly, yeah I changed the blog's title. As I'm using ONLY OpenBSD nowadays, I think it's appropriate to change the title as I don't use other type of BSD. Now back to the main story.

So far, this is a brief description of what I (initially) wanted to achieve:

Alpine+LDAP <---> DavMail <---> CompanyEmail@OWA/Exchange

So here's what I'm currently doing. Getting Alpine + DavMail to play nicely together. I have posted earlier that I compiled my Alpine with LDAP support so I can check my company's email address book. Here's the current status of the project:

DavMail <---> CompanyEmail@OWA: Working fine
Thunderbird <---> DavMail: Working fine

As DavMail is working, I can just focus on configuring Alpine. The first time I start Alpine (by typing Alpine in xterm), the program will create ~/.pinerc configuration file. I don't need to blow my head to configure Alpine as it has a great built-in configuration tool.

Chapter 1: Receiving emails.
Inside Alpine's Main menu [M], I just key [S] (Setup), [L] (collectionLists). Then inside Alpine's Setup Collection List page, I hit [A] (Add collection). Here's my configurations:

Nickname: MyCompany
Server: localhost:1143/user=ASIA\karl
Path:
View:


After I save & exit the configuration [Ctrl+X], Alpine requested for my email's password. I keyed in my password and Alpine ask for confirmation to exit the page. No error messages, so it's all good. Now to test it.

I go to Main [M], then hit [L] (Folder List). I can see 2 folders:

MAIL
   Local folders in mail/

MyCompany
   Folders on localhost:1143/user=ASIA\karl in home directory


I choose MyCompany and using the Right Arrow [>] key, Alpine opened up my company email. I can see all the folders I have there and I can read my emails. So far so good.

Chapter 2: Sending emails (Working now!).
I'm still configuring this part as it's not working. I'll just put the steps for revising purpose. If you have a working solution, do comment.

Thanks to Christopher for commenting and posting a usefull link. Surely, I managed to tweak Alpine's setting and managed to get the SMTP portion working for sending emails. Do take note that I'm already running a new version of DavMail so it'll be better for you guys to update too.

Inside Alpine's Main menu, I choose [S] (Setup) and [C] (Config). The mandatory line to be update is this:

SMTP Server (for sending) = localhost:1025/user=ASIA\karl

So here, I don't need to use user=ASIA\\karl because the single \ is not escaped.
As I stated, it's currently not working. I kept getting "Error sending" message if I want to send out email. Previously I tried user=ASIA\karl but the "\" got escaped in ~/.pinerc and I still can't send email.

If I can't sort this out, I might have to go with using Sendmail instead of going thru DavMail. I will post any updates on this. I've also added this line in the same Config's screen:

Inbox Path = {localhost:1143/user=ASIA\karl}inbox

Note that this setting depends on whether you need it or not. As I use Alpine only for 1 OWA account, I set this up. Now press [E] to exit and save the setting. Press [Q] to quit Alpine.

Now vim your .pinerc file, normally in your home folder (~/.pinerc) and change this line:

disable-these-authenticators=GSSAPI,PLAIN

Save the .pinerc file and open Alpine back. I composed [C] an email and wallah! Alpine asked for my OWA password and email is sent! Great!. Again, thanks Christopher!

Chapter 3: Using LDAP.
As I've compiled my Alpine with LDAP support, I can use it to search my company's email address book. Inside Alpine's Main menu, I choose [S] (Setup) and [D] (Directory). Inside Alpine's Setup Directory Servers page, I hit [A] (Add dir) and this is my settings:

ldap-server= localhost
search-base= ou=people
port= 1389
bind-dn= ASIA\karl
nickname= MyCompany


Then I hit [E] (Exit Setup) and [Y] to save changes. [E] to exit the Setup Directory Servers page.

To test out, inside Alpine's Main menu, I hit [A] (Address Book) and select MyCompany. I hit the Right Arrow [>] key and type a name to search. Alpine then requested for my password and after a while, list of matches appears. So this part is working too.

Chapter 4: Offline email reading.
Yes, there's no offline reading for Alpine using IMAP. So now I know. That's one of the most important feature I wanted to use. After searching for solutions, I found the most suitable option. This is the latest description of the (possible) solution:

Alpine+LDAP <---> UW-IMAPD <---> OfflineIMAP <---> DavMail <---> CompanyEmail@OWA

So, instead of getting Alpine to directly access DavMail, Now I need to set up UW-IMAPD and OfflineIMAP. UW-IMAPD is built as dependency for Alpine+LDAP. UW-IMAPD is a local IMAP server and OfflineIMAP is like what the name means, reading emails from IMAP server in offline mode. Now OfflineIMAP will retrieve emails from my company's exchange thru DavMail (OfflineIMAP can't directly retrieve exchange emails), then OfflineIMAP will sync the emails to my local IMAP server which is UW-IMAPD so I will have a local offline copy of my emails that I can use with Alpine. Here's the checklist of needed softwares:

- Alpine+ldap
- UW-IMAPD
- DavMail
- OfflineIMAP

Update 13/04/11: Thanks to Christopher's comment, I got my email sending working! Thank you very much! You guys should read his comment and go to the link posted. I've update this post to reflect the changes. Later then.

Tuesday, November 16, 2010

OpenBSD NC4200: Alpine + DavMail: DavMail configurations.

A bit of personal history. Bear with me as it might get you bored to death as it will be a long one. Ok, my company uses MS Exchange for emails. And, wait, I guess that just sums it up. Company uses MS Exchange, bla bla, I don't want to use Outlook, bla bla, I don't want to use MS Windows, bla bla so here I am. Basically, I just want to use Alpine / Thunderbird to access my company's exchange so I can receive and send emails. Bit of details about my profile and the company's email (this won't be a real one, just to show you how I done it):

Email: karl.bsd@company.com
Username: ASIA\karl
OWA Exchange: https://owa.company.com/exchange/

As you can see, the Username for me to log in to the OWA is different than my email add. To make things a bit more complicated, my internet access is through a http proxy which I will name as http://my.proxy.com at port 8080. Ok enough history class, now on to the good stuff.

For DavMail, it comes zipped with quite some files inside. From DavMail's website, I choose Workstation (personal) mode > Other DavMail release. What contains inside mine is:

lib (folder with lots of *.jar files)
davmail.jar
davmail.sh


I created ~/davmail/ folder and extracted the archive inside it. In basic, I can just use:

$ sh ~/davmail/davmail.sh &

And the familiar DavMail icon will appear in XFCE's taskbar. But that's for XFCE. As wmii's status bar is not a task bar, DavMail will not have the icon. In XFCE, right clicking the DavMail icon and choosing settings, I just put my OWA address in the DavMail url. Then I choose to set the proxy server with the 8080 port. I left all the other setting to default.

XFCE + Thunderbird + DavMail:
This part is quite easy. There's numerous documentations / HOWTOs on this. Even the official DavMail website have tutorial on setting up Thunderbird to work with DavMail. I just follow the documentation and it's working ok. I can send receive emails, do LDAP queries and even sync with the company's calendar using Thunderbird+Lightning+CalDav. Just remember to install lightning using packages as there will be none available in Thunderbird's AddOn website for OpenBSD. As I've stated earlier, sh ~/davmail/davmail.sh & is enough to get you started with DavMail in XFCE.

wmii + Alpine + DavMail:
Now this is THE thing. wmii and normal DavMail don't quite play nicely. By saying "normal" I mean using the command I stated above. There's no taskbar for DavMail to icon-er-ify(?) to. The solution? A quick google and I found something about DavMail configuration file. Shamelessly following the said information, I created davmail.properties file inside ~/davmail/ folder. Here's my davmail.properties file, important bits are bolded for your pleasure:

davmail.url=https://owa.company.com/exchange/
davmail.popPort=1110
davmail.imapPort=1143
davmail.smtpPort=1025
davmail.caldavPort=1080
davmail.ldapPort=1389
davmail.keepDelay=30
davmail.sentKeepDelay=90
davmail.imapIdleDelay=
davmail.useSystemProxies=false
davmail.enableProxy=true
davmail.proxyHost=my.proxy.com
davmail.proxyPort=8080

davmail.proxyUser=
davmail.proxyPassword=
davmail.ssl.keystoreType=JKS
davmail.ssl.keyPass=
davmail.ssl.keystorePass=
davmail.server=true
davmail.server.certificate.hash=
davmail.bindAddress=
davmail.allowRemote=true
davmail.disableUpdateCheck=false
log4j.rootLogger=WARN
log4j.logger.davmail=DEBUG
log4j.logger.org.apache.commons.httpclient=WARN
log4j.logger.httpclient.wire=WARN
davmail.logFilePath=/var/log/davmail.log


For davmail.proxyHost=, previously I was tearing my hairs apart because normal DavMail is working fine but not so when I use the davmail.properties file. When I tried using my.proxy.com instead of http://my.proxy.com, wallah! The earth smiles back at me. davmail.useSystemProxies= is "false" and davmail.enableProxy= is "true" so that instead of using the (currently malfunctioned) System Proxy, DavMail will use the proxy address I specified. Then I need to set the davmail.server= to "true" so that DavMail will not show any icon / GUI and be in daemon mode. I also need to chmod the /var/log/ folder so that DavMail can properly write logs inside there. After all is done, I do testing with:

$ sudo sh ~/davmail/davmail.sh ~/davmail/davmail.properties &

I opened up Thunderbird and all is good. Now to get DavMail started everytime I log in wmii. I mentioned earlier that I use SLiM login manager to replace xdm. SliM can let me choose what window manager / desktop environment I want to log in and that's something xdm currently don't have. I posted my ~/.xinitrc script earlier and this is the changes I need to make to get DavMail started after my login:

# This is for SLiM

case $1 in
wmii)
 xscreensaver &
 nohup sh ~/davmail/davmail.sh ~/davmail/davmail.properties &
 eval `cat ~/.fehbg`
 exec wmii
 ;;


You can follow the rest of the script by searching my previous post. As for the nohup, man nohup will give you great explaination. I log out from wmii and re-login. Open up Thunderbird and it's working alright. Eh, wait.. Thunderbird?! Where's the Alpine's stuff?! Whoa hold yer horses mate. That part will need another post.

Coming up next. Getting Alpine to work with DavMail. Or almost.

OpenBSD NC4200: Alpine + DavMail, ftp_proxy / http_proxy problem again.

Here's the latest update for my Alpine + DavMail project. Installing Alpine via OpenBSD's package doesn't come with LDAP support enabled. I can verify that by using:

$ alpine -supported

So, I read the OpenBSD ports system man pages and Alpine ports man pages and found that I need to specify the ldap flavor when building the Alpine ports. So in /usr/ports/mail/alpine directory, I use this syntax to build Alpine port with ldap built-in.

$ sudo env FLAVOR="ldap" make install
$ sudo env FLAVOR="ldap" make clean


That's when I found out that my ftp_proxy / http_proxy is unusable. Again. Sheesh! I don't know what happened to it and I'm still searching for solution. So, I downloaded the needed dependencies manually and put it inside /usr/ports/distfiles/. After a while the Alpine with ldap support is installed. Oh I need to remove the previous Alpine installation before the new Alpine can be installed. Alpine-ldap is installed and so do DavMail. Now for the good stuff. Making them work (nicely) together. For that, I'll write it in another post.

Coming up next: My DavMail configurations

Monday, November 15, 2010

OpenBSD NC4200: wmiirc, updated status bar script, SLiM login manager & Alpine with Davmail

Using my previous posting as reference, I copied /etc/wmii-3.5/wmiirc to ~/.wmii-3.5/wmiirc then added all the status bar scripts. I also change the following:

# Configuration Variables
MODKEY=Mod4


WMII_TERM="mrxvt"

And then added my status bar script. Surprisingly (or not), I made a few mistakes in my last status bar script I posted previously. You see, I copied the script by typing manually to blogspot, rather than using a text editor's copy/paste function. Furthermore, some of the mistakes are less forgiven in OpenBSD 4.8 than in previous installation. The battery status is not working properly in 4.8. I guess I haven't tested the script thoroughly before although I think previously the script was working ok. Now I've rewritten the battery status script and it seems to be working fine now. So here I'll post the (hopefully) working version of my status bar script. It's still displaying the system cpu usage, free memory, main/extended battery status, a/c adapter status & date time. As for WMII_TERM="mrxvt", that's because I installed mrxvt to replace xterm in wmii.

Here's the updated script for my wmii Status Bar:

# Status Bar info
status() {

 # This is for the main battery, if there's none, just display nothing.
 if [[ $(sysctl -n hw.sensors.acpibat0) != '' ]]; then
  bat0full=$(sysctl -n hw.sensors.acpibat0.amphour0 | sed s/.A.*//)
  bat0warn=$(sysctl -n hw.sensors.acpibat0.amphour1 | sed s/.A.*//)
  bat0low=$(sysctl -n hw.sensors.acpibat0.amphour2 | sed s/.A.*//)
  bat0now=$(sysctl -n hw.sensors.acpibat0.amphour3 | sed s/.A.*//)

  # Get the battery capacity in percentage
  bat0cap=`echo "100 * ${bat0now} / ${bat0full}" | bc`
  bat0p="$bat0cap%"

  # Get the charging status of the battery, replace with symbols
  bat0s=$(sysctl -n hw.sensors.acpibat0.raw0 | sed 's/'0'.*//; s/'1'.*/-/; s/'2'.*/+/; s/'4'.*/!/')
 else
  bat0p=`echo ""`
  bat0s=`echo ""`
 fi

 # This is for extended battery, if it's installed, display the status. Else just display nothing.
 if [[ $(sysctl -n hw.sensors.acpibat1) != '' ]]; then
  bat1full=$(sysctl -n hw.sensors.acpibat1.amphour0 | sed s/.A.*//)
  bat1warn=$(sysctl -n hw.sensors.acpibat1.amphour1 | sed s/.A.*//)
  bat1low=$(sysctl -n hw.sensors.acpibat1.amphour2 | sed s/.A.*//)
  bat1now=$(sysctl -n hw.sensors.acpibat1.amphour3 | sed s/.A.*//)

  # Get the battery capacity in percentage
  bat1cap=`echo "100 * ${bat1now} / ${bat1full}" | bc`
  bat1p="$bat1cap%"

  # Get the charging status of the battery, replace with symbols
  bat1s=$(sysctl -n hw.sensors.acpibat1.raw0 | sed 's/'0'.*//; s/'1'.*/-/; s/'2'.*/+/; s/'4'.*/!/')
 else
  bat1p=`echo ""`
  bat1s=`echo ""`
 fi

 # Get the AC Adapter status
 ac0=$(sysctl -n hw.sensors.acpiac0.indicator0 | sed s/.'('.*//)

 # Get the free memory data using top
 memfree=$(top | grep Memory | sed 's/.*Free:.//; s/.Swap.*//')

 # Get the CPU usage via top
 cpuuse=$(top | grep 'CPU states:' | sed 's/.*nice..//; s/.sys.*//')

 # Display the status bar
 echo CPU: $cpuuse '|' Mem: $memfree '|' Bat: ${bat0p}${bat0s} ${bat1p}${bat1s} '|' AC: $ac0 '|' $(date)

}


Another thing, I changed the X Display Manager to Simple LogIn Manager (SLiM). I would've stick with xdm if not for the fact that xdm (currently) can't let me choose which X session I want to start (wmii or XFCE4). After I installed SLiM, I opened up /etc/rc.local and added:

# Add your local startup actions here.
# This is for SLiM
if [ -x /usr/local/bin/slim ]; then
 echo -n ' slim'; /usr/local/bin/slim -d &
fi

echo '.'


Do make sure that xdm has been disabled in /etc/rc.conf.local or /etc/rc.conf. After that I edited SLiM's config file /etc/slim.conf:

# NOTE: if your system does not have bash you need
# to adjust the command according to your preferred shell,
# i.e. for freebsd use:
login_cmd exec /bin/ksh -l ~/.xinitrc %session


# Available sessions (first one is the default).
# The current chosen session name is replaced in the login_cmd
# above, so your login command can handle different sessions.
# see the xinitrc.sample file shipped with the slim sources
sessions wmii,xfce4


Unfortunately installing the SLiM from package doesn't provide me with xinitrc.sample stated above. After googling for samples, I managed to edit my ~/.xinitrc for SLiM's use:

# This is for SLiM
DEFAULT_SESSION=wmii

case $1 in
wmii)
 xscreensaver &
 eval `cat ~/.fehbg`
 exec wmii
 ;;
xfce4)
 exec startxfce4
 ;;
*)
 xscreensaver &
 eval `cat ~/.fehbg`
 exec $DEFAULT_SESSION
 ;;
esac


Now at SLiM's login screen, I can choose the window manager I want to use with F1. Currently I'm having problem to reload background wallpaper for wmii using feh and searching for solution. It seems that eval `cat ~/.fehbg` is the correct command for it, not `cat ~/.fehbg` As for SLiM, halt and reboot command doesn't work yet. More on that later.

Oh yeah, I'm back on wmii. Not that I don't like xfce. Well xfce is a great desktop environment. But there's something about wmii that kept getting back at me. Currently I'm still using Thunderbird with DavMail, still trying to set up Alpine with DavMail. Will post something on that later.

Update: I'm back to xterm instead of mrxvt. Using xterm-256color is enough for me.

Update: I was thinking about giving a preview on what will be displayed on the status bar. So here it is. This preview is my machine on extended battery (which is charging), on AC adapter. Sorry no fancy picture or anything:

CPU: 4.5% | Mem: 456M | Bat: 100% 76%+ | AC: On | Fri Dec 10 15:27:10 MYT 2010

Thursday, January 28, 2010

OpenBSD NC4200: Alpine trough OpenSMTPD went fine.

Ah, done testing Alpine email client with OpenSMTPD and it's working fine. In Alpine, I go to "Setup" to configure Alpine and choose "Config". Then in the "SMTP Server (for sending)" line, I just put localhost as the value and then exit the setting. I composed an email and it went through just fine. Great. Bye bye sendmail.

6.5 amd64: Modify existing certbot certificates.

Hi, It's been quite some time eh. As you can see, I still upgrade my OpenBSD system regularly but currently I do not have the time to ...