微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Python pyasn1.error 模块-SubstrateUnderrunError() 实例源码

Python pyasn1.error 模块,SubstrateUnderrunError() 实例源码

我们从Python开源项目中,提取了以下50代码示例,用于说明如何使用pyasn1.error.SubstrateUnderrunError()

项目:oscars2016    作者:0x0ece    | 项目源码 | 文件源码
def indefLenValueDecoder(self, fullSubstrate, substrate, asn1Spec, tagSet,
                             length, state, decodeFun, substrateFun):
        r = self._createComponent(asn1Spec, '')
        if substrateFun:
            return substrateFun(r, length)
        while substrate:
            component, substrate = decodeFun(substrate, self.protoComponent,
                                             allowEoo=True)
            if eoo.endOfOctets.isSameTypeWith(component) and \
                    component == eoo.endOfOctets:
                break
            r = r + component
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
                )
        return r, substrate
项目:oscars2016    作者:0x0ece    | 项目源码 | 文件源码
def indefLenValueDecoder(self, tagSet)
        if substrateFun:
            return substrateFun(r, length)
        idx = 0
        while substrate:
            asn1Spec = self._getComponentTagMap(r, idx)
            component, allowEoo=True)
            if eoo.endOfOctets.isSameTypeWith(component) and \
                    component == eoo.endOfOctets:
                break
            idx = self._getComponentPositionByType(
                r, component.getEffectiveTagSet(), idx
                )            
            r.setComponentByPosition(idx, component, asn1Spec is None)
            idx = idx + 1                
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
                )
        r.setDefaultComponents()
        r.verifySizeSpec()
        return r, length)
        asn1Spec = r.getComponentType()
        idx = 0
        while substrate:
            component, allowEoo=True)
            if eoo.endOfOctets.isSameTypeWith(component) and \
                    component == eoo.endOfOctets:
                break
            r.setComponentByPosition(idx, asn1Spec is None)
            idx = idx + 1                
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
                )
        r.verifySizeSpec()
        return r, substrate
项目:noc-orchestrator    作者:DirceuSilvaLabs    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:GAMADV-XTD    作者:taers232c    | 项目源码 | 文件源码
def indefLenValueDecoder(self,
                             tagSet=None, length=None, state=None,
                             decodeFun=None, substrateFun=None,
                             **options):
        bitString = self._createComponent(asn1Spec, tagSet)

        if substrateFun:
            return substrateFun(bitString, length)

        while substrate:
            component,
                                             allowEoo=True, **options)
            if component is eoo.endOfOctets:
                break

            bitString += component

        else:
            raise error.SubstrateUnderrunError('No EOO seen before substrate ends')

        return bitString, substrate
项目:zeronet-debian    作者:bashrc    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate = decodeFun(substrate)
            if eoo.endOfOctets.isSameTypeWith(component) and \
                    component == eoo.endOfOctets:
                break
            r = r + component
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
                )
        return r, asn1Spec)
            if eoo.endOfOctets.isSameTypeWith(component) and \
                    component == eoo.endOfOctets:
                break
            idx = self._getComponentPositionByType(
                r, substrate
项目:plugin.video.bdyun    作者:caasiu    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:aws-cfn-plex    作者:lordmuffin    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:AshsSDK    作者:thehappydinoa    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrateFun):
        bitString = self._createComponent(asn1Spec, allowEoo=True)
            if component is eoo.endOfOctets:
                break

            bitString += component

        else:
            raise error.SubstrateUnderrunError('No EOO seen before substrate ends')

        return bitString, substrateFun):
        if substrateFun and substrateFun is not self.substrateCollector:
            asn1Object = self._createComponent(asn1Spec, tagSet)
            return substrateFun(asn1Object, length)

        # All inner fragments are of the same type,treat them as octet string
        substrateFun = self.substrateCollector

        header = null

        while substrate:
            component,
                                             self.protoComponent,
                                             substrateFun=substrateFun,
                                             allowEoo=True)
            if component is eoo.endOfOctets:
                break
            header += component
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
            )
        return self._createComponent(asn1Spec, header), substrateFun):
        asn1Object = self._createComponent(asn1Spec, tagSet)
        if substrateFun:
            return substrateFun(asn1Object, length)
        asn1Spec = asn1Object.componentType
        idx = 0
        while substrate:
            component, allowEoo=True)
            if component is eoo.endOfOctets:
                break
            asn1Object.setComponentByPosition(
                idx,
                verifyConstraints=False,
                matchTags=False, matchConstraints=False
            )
            idx += 1
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
            )
        asn1Object.verifySizeSpec()
        return asn1Object, substrate
项目:Intranet-Penetration    作者:yuxiaokui    | 项目源码 | 文件源码
def indefLenValueDecoder(self, idx
                )
            r.setComponentByPosition(idx, asn1Spec is None)
            idx = idx + 1
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
                )
        r.setDefaultComponents()
        r.verifySizeSpec()
        return r, substrate
项目:MKFQ    作者:maojingios    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:REMAP    作者:REMAPApp    | 项目源码 | 文件源码
def indefLenValueDecoder(self, allowEoo=True)
            if eoo.endOfOctets.isSameTypeWith(component) and component == eoo.endOfOctets:
                break

            bitString += component

        else:
            raise error.SubstrateUnderrunError('No EOO seen before substrate ends')

        return bitString,
                                             allowEoo=True)
            if eoo.endOfOctets.isSameTypeWith(component) and \
                    component == eoo.endOfOctets:
                break
            r = r + component
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
            )
        return r,
                                     verifyConstraints=False,
                                     matchTags=False, matchConstraints=False)
            idx += 1
        else:
            raise error.SubstrateUnderrunError(
                'No EOO seen before substrate ends'
            )
        r.verifySizeSpec()
        return r, substrate
项目:xunfeng    作者:ysrc    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:ysrc    作者:myDreamShadow    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:OneClickDTU    作者:satwikkansal    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:pelisalacarta-ce    作者:pelisalacarta-ce    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate
项目:plugin.video.streamondemand-pureita    作者:orione7    | 项目源码 | 文件源码
def indefLenValueDecoder(self, substrate

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐