Use cheat search every couple seconds, find a value that keeps decreasing.
According to datacrystal, it's $079F. Using FCEUXD SP, set a write breakpoint for that address to track down the code that changes it.
Never mind, I found it: Change the byte at address 0x5827 to 0x46 to extend the Star Man time to twice the default value.
;--------------------------------------------------------------------
; $d800-$d81f ( 0x5810 - 0x582f ) handle power-up collision routine
HandlePowerUpCollision:
jsr EraseEnemyObject ;erase the power-up object
lda #$06
jsr SetUpFloateyNumber ;award 1000 points to the player by default
lda #SFX_PowerUpGrab
sta Square2SoundQueue ;play the power-up sound
lda PowerUpType ;check power-up type
cmp #$02
bcc Shroom_Flower_PUp ;if Super Mushroom or Fire Flower, branch
cmp #$03
beq SetFor1Up ;if 1-Up Mushroom, branch
lda #$23 ;otherwise set Star Mario invincibility
sta StarInvincibleTimer ;timer, and load the Star Mario music
lda #StarPowerMusic ;into the area music queue, then leave
sta AreaMusicQueue
rts