Bezpieczeństwo, tożsamość, prywatność – aspekty prawne