I'm not aware of any passport number for Bond being given in Ian Fleming's novels or short stories — as far as I know, Fleming never specified one, so any number you see quoted is likely either from the films, from continuation novels by other authors, or simply invented by fans.
Fleming did supply plenty of other bureaucratic detail about Bond, which may be what you're thinking of:
- **007** — his double-O licence-to-kill number within the Secret Service.
- **Commander, Royal Naval Volunteer Reserve** — his wartime rank, which he retains.
- A detailed SMERSH dossier on him appears in *From Russia, with Love*, listing his height, weight, distinguishing marks and known aliases.
- He travels under cover identities in several books, such as "Peter Franks" in *Diamonds Are Forever* and "David Somerset" in *Goldfinger*.
If you've seen a specific number cited somewhere, it would help to know the source — it may come from one of the films (props like Bond's passport have appeared on screen) rather than from Fleming himself.