Merge pull request #92 from hacknix/master

Whitelist allow IDs should be above 99999 not 10000
This commit is contained in:
Jonathan Naylor 2016-06-11 13:59:47 +01:00 committed by GitHub
commit 26618bc832
2 changed files with 4 additions and 4 deletions

View file

@ -1488,9 +1488,9 @@ bool CDMRSlot::DstIdWhitelist(unsigned int did, unsigned int slot, bool gt4k)
if (slot == 1) { if (slot == 1) {
if(m_dstWhiteListSlot1.size() == 0) if(m_dstWhiteListSlot1.size() == 0)
return true; return true;
// No reflectors on slot1, so we only allow all IDs over 10000 unless specifically whitelisted. // No reflectors on slot1, so we only allow all IDs over 99999 unless specifically whitelisted.
if(gt4k) { if(gt4k) {
if (std::find(m_dstWhiteListSlot1.begin(), m_dstWhiteListSlot1.end(), did) != m_dstWhiteListSlot1.end() || did >= 10000) { if (std::find(m_dstWhiteListSlot1.begin(), m_dstWhiteListSlot1.end(), did) != m_dstWhiteListSlot1.end() || did >= 99999) {
return true; return true;
} }

View file

@ -16,9 +16,9 @@ If the whitelist is null and commented out, it is disabled.
The whitelist behaves slightly differently on Slot1 than is does on Slot2. The whitelist behaves slightly differently on Slot1 than is does on Slot2.
For Slot1, the whitelist will allow all IDs above 10000 and everything in the whitelist. For Slot1, the whitelist will allow all IDs above 99999 and everything in the whitelist.
For Slot2, the whitelist will allow all IDs between 4000 and 5000, IDs above 10000 and everything in the whitelist. For Slot2, the whitelist will allow all IDs between 4000 and 5000, IDs above 99999 and everything in the whitelist.
You can use the blacklist with the whitelist if you want to specifically block IDs within the allowed ranges above. You can use the blacklist with the whitelist if you want to specifically block IDs within the allowed ranges above.