Not sure of your exact model but most have a thermocoupler just above the pilot light
that the pilot light
heats up and when it gets hot enough it tells the control valve "Hey i've got a pilot light
now i can turn on the furnace" maybe the thermocoupler is not over the pilot light or went bad?? If not i would suspect the main controller at that point.....this is just a free test you can do yourself before taking it to a pro.
Sure hope it's just the thermocoupler out of line or gone bad (they're not expensive)