If they're surface cracks then it's from the hoof getting wet and then drying out. At least that's what I recall from studying hoof care.
Also If I recall correctly you should avoid putting oil on the hoof wall. And please don't quote me on this, do some research to find out for sure cus I could be remembering wrong. Something about the oil not allowing the hoof wall to also absorb moisture cus it creates a barrier that doesn't allow water in. Basically it doesn't allow the hoof wall to breath. Again, I could be wrong on my memory here cus it's been a while since I read about surface cracks. This is something I learned here on these forums.
If you're talking about an actual hoof wall crack running from ground up to the coronet. These can be grown out with proper trimming. I bought Pete Ramey's dvd's. The 10 disk set and I trim my horses using a barefoot trim. Breakover where it needs to be. Heel height where it needs to be. And mustang roll. I've successfully grown out wall cracks doing this.
I want to also mention that I've had a trimmer come out that told me she was a barefoot trimmer. She told me that they can't be grown out, only managed. But in hindsight recalling how she trimmed the hooves..... I wouldn't call her a very competent barefoot trimmer. Basically I just wanted to say that not all trimmers have, nor use the same type of knowledge.
Truth passes through three stages. First it is ridiculed. Second it is violently opposed. Third it is accepted as self evident.