Just by hunting down the Wiki-page and reading the article that the page refers to I was able to find some insight into how the channel works, at least to some degree. (For the record the wiki-page is a much easier read than the journal-article.)
The gist of it - Because water binds differently (more strongly) to Sodium than to Potassium and "The selectivity filter (which)is formed by five residues (TVGYG-in prokaryotic species) in the P loop from each subunit which have their electro-negative carbonyl oxygen atoms aligned towards the centre of the filter pore and form an anti-prism similar to a water solvating shell around each potassium binding site" So it is more energetically favorable to pull off water from a Potassium ion and let the channel's binding site collapse on the Potassium ion and let it pass through the channel. But since Sodium binds more strongly to water it is unfavorable for the binding site to collapse on the ion and let it pass.
Well that's the short of it. So it is the P loop that does the selectivity based on the ion's affinity for water.