It's an original riff called "Miss Gulch's / Witch's theme" by Herbert Stothart, who won an Oscar for the film's score. Also, according to Wiki:
This repeated seven-note motif is actually a "crippled" variation (inverted and compressed in range) of the musical figure for "We're off to see the Wizard".
Here's an interesting article (archive.org copy) about the music in the film (this riff included).