Support for Oscam-emu. Working keys being overwritten

There are 8 replies in this Thread which was already clicked 1,123 times. The last Post () by supwiddiss.

  • I could use some help with a problem. I have 3 channels right now. 2 are on one tp, 2 on another. When Oscam writes new keys at the bottom the keys file, one channel quits clearing.
    I can get that one working again then once it writes a set of keys the other 2 quit clearing. It's a real juggling act.
    I've tried changing the group ID. They all did begin with P 0101XXXX. For 2 channels I changed the group to P1101XXXX, and left the other as it was.
    I've tried taking the ua and making dummy keys for 2 channels and a different dummy for the other. The same thing keeps happening.
    I never did catch on to using the new method with hash. Perhaps a little help please?
    In the attachment is the added by Emu portion of the keys file.
    Where the blank lines are is where I deleted the SID keys for channels that stopped working. A restart of oscam restored the channels for a bit until ua happened again.
    Help!!!


    UA.list

    • Official Post

    How have you got your EMM key's for the channels concerned ??

    Can you post those to please, also full sid tsid and service reference, sat location etc etc


    https://github.com/oscam-emu/o…tched/wiki/PowerVU-config

    • Official Post


    Matching ECM and EMM keys based on transponder (new method - May 2019)

    The traditional method of getting ECM keys is based on matching the srvid of the channel only. This means the ECM algorithm does not match the group id at all when searching for the ECM key. If many ECM keys with the same srvid (see Note 1 below) are present in the SoftCam.Key, they are all tried until the correct one is found.

    In addition, the EMM algorithm does not match the group id as well. The EMM keys used for auto updating can be chosen from various groups (see Note 3) and as a result wrong EMM keys can be used.

    The new approach is to utilize the group id of the channel when the ECM and EMM algorithms run. In order OSCam-Emu to know what is the correct group id to use, it calculates a hash based on tsid, onid and enigma namespace of the transponder. The user then needs to enter a new line in the SoftCam.key telling OSCam-Emu which group id to use for each transponder (hash).

    The syntax for this line is the following:

    Code
    P <hash> GROUP <groupid>

    Where:

    Code
    hash    (4 bytes) :  Transponder hash calculated automatically by OSCam-Emu. Use debug level 2 to display it.
    groupid (2 bytes) :  The group id that is used for the ECM and EMM keys.

    Example:

    Code
    P BF175115 GROUP 0080 ; 12303 V, 0.8°W
    P ACE05CA0 GROUP 0080 ; 12360 V, 4.8°E
    
    P 9798A8F2 GROUP 0900 ; 11804 V, 9.0°E

    Transponders using the same ECM and EMM keys should use the same group (this should be the case for the traditional method as well) and thus multiple "GROUP" entries should exist for that group id.

    After adding the GROUP instruction for a group, the next step is to remove all ECM keys for that group and enter a new one with the dummy srvid 0xFFFF. For example:

    Code
    P 0900FFFF 00 00000000000000 ; ECM Key
    P 0900FFFF 01 00000000000000 ; ECM Key

    The EMM keys should remain untouched. After restarting the Emu reader, the new method should take over for both the ECM algorithm and the EMM (AU) aglorithm.

    The advantages of this new method are many:

    • One ECM key is used for all channels in a transponder, so the SoftCam.Key has smaller size and it's easier to maintain and update.
    • Memory consumption is lower and getting the correct key is faster.
    • All problems described in Note 3 are disappeared, which makes creating a proper, trouble-free SoftCam.Key easier for all.

    On the other hand there is one drawback: The application of this new method is limited to STBs utilizing the enigma namespace, like enigma2 boxes and TVheadend, VDR, etc.


    Note 1

    For channels with the same service id, the correct ECM key will be detected automatically, but each key needs a unique groupid. If you need different ECM keys for channels with the same service id, make sure they belong to different groups, like in the example:

    Code
    P 009E0234 01 11223344556677
    P 00040234 01 22334455667788
    P 013E0234 01 33445566778899

    Duplicate keys (same groupid and same srvid) are not allowed. If there are any duplicates, only the last one in the SoftCam.Key file will be used. This also means that as new ECM keys are found and appended to the file, they will automatically replace earlier keys.


    Note 2

    In order the auto update feature to work, the ECM keys must be seeded. This is done by entering a dummy ECM key and a corresponding (i.e. with the same group id) EMM key, for example:

    Code
    P 00010004 00 00000000000000
    P 00010004 01 00000000000000
    
    P 0001 AABBCCDD 11223344556677

    When you tune into the channel with the service id '0004', the auto update function will run. After a while, a new ECM key will be written at the bottom of the SoftCam.Key file. This new ECM key will be used instead of the dummy one when opening the channel. For each service id, a dummy ECM key has to be added. Each EMM key will update all ECM keys in the same group.


    Note 3

    Multiple EMM keys are allowed for each group, but there is a maximum number of 32 EMM keys that will be used when auto updating. When the auto update function runs, the algorithm does not match the group id. This means that these 32 EMM keys are chosen among all groups that have an ECM key with the current channel's service id, and not necessarily from the 'correct' group. The effective number of EMM keys for auto updating is thus 32 per service id (channel). This design has two side effects:

    • If there are many EMM keys for each group, there is a chance all 32 EMM keys are chosen from the 'wrong' group. Then the auto update function will never update the ECM keys.
    • Since no group id is matched, there is a chance the newly found ECM keys to be written to the 'wrong' group.

    For best results, it is recommended to have no more than 10 EMM keys in each group, especially if you have many groups in your SoftCam.Key file, and make sure there are no EMM keys with the same UA belonging to different groups.

    When using the new method for matching ECM and EMM keys based on transponder, all considerations described above are gone. Only limitation is the maximum number of EMM keys that can be used per group are 32.

  • Hi. Keys written to stopped Friday but probably will start again soon.
    The post above I've read multiple times. It's a bit hard to granulate and relate to what might help me out.
    The hash method interests me but not so clear on it and if my entire keys file has to be sanitized to work. That comes later on.
    Right now I see an occasional message that's not really covered elsewhere. What the heck is an fd?
    (dvbapi) ERROR: error on poll of 8 fd's (errno=2 No such file or directory)
    Will stay in touch. I'm going to ace this one.

    • Official Post

    Think it would be best to do the whole key file TBH, like in this example


    separating TP's and sats where required....i know it will take a long time to sort, but once done will be easy to maintain.


    This bit also make it a lot easier:

    hash (4 bytes) : Transponder hash calculated automatically by OSCam-Emu. Use debug level 2 to display it.

  • I'm back on this one. Keys "added byEmu" started again today.
    My attached file is hopefully clearly noted. I'll certainly assist if it's not clear what's going on.
    SID 02BD, 00C9, 0203 were clearing until the added by happened at 16:18.
    No new keys have been added for a week.
    I temporarily deleted that section and restarted oscam. All 3 channels cleared again.

    I know it may be confusing. There is a flip-flop happening.
    I lose 02BD and 00C9 but 0203 clears after the update.
    If I land on 02BD or 00C9 for a few minutes they clear but then I lose 0203.
    Right now it's been 30 minuites and 0203 hasn't cleared. 02BD and 00C9 do.

    Any ideas?

    Edit:
    Right now I'm seeing that while watching 02BD or 009C a new set of keys will be written. I have a new key for 0203. That channel stops clearing. Deleting the new keys (00,01) for 203 and restarting oscam will let it clear. New keys have been written twice in 1/2 hour or so.

    • Official Post

    Hi. Just stopping by to do some dusting and to spray a little Lysol to keep the moss down.
    Anyone?

    i have not had the time to check, have you sorted your softcam.key ?

    Perhaps best to attach that

    Your best bet for help with this is W@Rp if he is available.

OSCam-EMU Support Forum

Configs, discussion, downloads and guides for OSCam-EMU Softcam.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!