Analysis of Grain Boundary Permeation in Solids