Functional Safety and Security in Embedded Systems