De Wookiepedia :
Organa entrusted R2-D2 and C-3PO to Raymus Antilles, the Captain of the Tantive IV, who was instructed to treat them well and to wipe C-3PO's memory. Although R2-D2's inability to speak basic spared him from experiencing a memory wipe, it did undergo reprogramming to restrict access to the holo-recordings of Leia's birthparents, including Skywalker choking Amidala and her deathbed during delivery, to ensure that Leia's true parentage remained a secret.'
Eu acho que para o C-3PO a situação é clara: Após a sua limpeza da memória, ele não deveria ter sido capaz de lembrar que Vader era Anakin. Para o R2-D2 é muito provável que a reprogramação o tenha impedido de dizer a Luke que Skywalker é Vader.