add sid check for backward compatibility. Ref: KeeAgent/#4, KeeAgent/#46