Coalition and Labor strike deal on encryption legislation