Skip to content

Commit

Permalink
if the control the beginning of a call has valid crypto data, use the…
Browse files Browse the repository at this point in the history
… MI for the HDU;
  • Loading branch information
gatekeep committed Jul 16, 2024
1 parent 47d89fe commit dbe1f69
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/host/p25/packet/Voice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1621,6 +1621,10 @@ void Voice::writeNet_LDU1()
uint8_t mi[MI_LENGTH_BYTES];
::memset(mi, 0x00U, MI_LENGTH_BYTES);

if (control.getAlgId() != ALGO_UNENCRYPT && control.getKId() != 0) {
control.getMI(m_lastMI);
}

if (m_netLastLDU1.getAlgId() != ALGO_UNENCRYPT && m_netLastLDU1.getKId() != 0) {
control.setAlgId(m_netLastLDU1.getAlgId());
control.setKId(m_netLastLDU1.getKId());
Expand Down

0 comments on commit dbe1f69

Please sign in to comment.