I have a few different JPEG images I\'ve been testing with. As far as I\'ve seen the 0th and first bytes are always 0xFF and 0xD8.
0xFF
0xD8
The s
Those first two bytes are the JPEG SOI marker so are always present.
The 2nd and 3rd bytes appear to store meta data, which probably isn't present in every JPEG.
Further Reading.