你好,是可以合法工作的。但是要注意H-1B extension不能pending 超过240天。
“Although you are out of status, you may be permitted, depending on your classification, to continue your previously authorized employment for a maximum period of 240 days while your extension application is pending if USCIS receives your application before your Form I-94 expires, and you have not violated the terms of your nonimmigrant status. You may be required to stop working immediately when the first of the following events occurs:
• 240 days elapses from the date your I-94 expires; or
• USCIS has made a final decision denying your extension application.”
如果pending太久的话,可以跟公司商量考虑加急处理,移民局会在15天内给一个结果。