This text is a popular narrative in Jain tradition, especially within the Shvetambara sect.