@@ -3987,7 +3987,11 @@ module Impl<FullStateConfigSig Config> {
3987
3987
3988
3988
private newtype TSummaryCtx3 =
3989
3989
TSummaryCtx3None ( ) or
3990
- TSummaryCtx3Some ( PartialAccessPath ap )
3990
+ TSummaryCtx3Some ( DataFlowType t )
3991
+
3992
+ private newtype TSummaryCtx4 =
3993
+ TSummaryCtx4None ( ) or
3994
+ TSummaryCtx4Some ( PartialAccessPath ap )
3991
3995
3992
3996
private newtype TRevSummaryCtx1 =
3993
3997
TRevSummaryCtx1None ( ) or
@@ -4004,18 +4008,19 @@ module Impl<FullStateConfigSig Config> {
4004
4008
private newtype TPartialPathNode =
4005
4009
TPartialPathNodeFwd (
4006
4010
NodeEx node , FlowState state , CallContext cc , TSummaryCtx1 sc1 , TSummaryCtx2 sc2 ,
4007
- TSummaryCtx3 sc3 , DataFlowType t , PartialAccessPath ap
4011
+ TSummaryCtx3 sc3 , TSummaryCtx4 sc4 , DataFlowType t , PartialAccessPath ap
4008
4012
) {
4009
4013
sourceNode ( node , state ) and
4010
4014
cc instanceof CallContextAny and
4011
4015
sc1 = TSummaryCtx1None ( ) and
4012
4016
sc2 = TSummaryCtx2None ( ) and
4013
4017
sc3 = TSummaryCtx3None ( ) and
4018
+ sc4 = TSummaryCtx4None ( ) and
4014
4019
t = node .getDataFlowType ( ) and
4015
4020
ap = TPartialNil ( node .getDataFlowType ( ) ) and
4016
4021
exists ( explorationLimit ( ) )
4017
4022
or
4018
- partialPathNodeMk0 ( node , state , cc , sc1 , sc2 , sc3 , t , ap ) and
4023
+ partialPathNodeMk0 ( node , state , cc , sc1 , sc2 , sc3 , sc4 , t , ap ) and
4019
4024
distSrc ( node .getEnclosingCallable ( ) ) <= explorationLimit ( )
4020
4025
} or
4021
4026
TPartialPathNodeRev (
@@ -4043,9 +4048,9 @@ module Impl<FullStateConfigSig Config> {
4043
4048
pragma [ nomagic]
4044
4049
private predicate partialPathNodeMk0 (
4045
4050
NodeEx node , FlowState state , CallContext cc , TSummaryCtx1 sc1 , TSummaryCtx2 sc2 ,
4046
- TSummaryCtx3 sc3 , DataFlowType t , PartialAccessPath ap
4051
+ TSummaryCtx3 sc3 , TSummaryCtx4 sc4 , DataFlowType t , PartialAccessPath ap
4047
4052
) {
4048
- partialPathStep ( _, node , state , cc , sc1 , sc2 , sc3 , t , ap ) and
4053
+ partialPathStep ( _, node , state , cc , sc1 , sc2 , sc3 , sc4 , t , ap ) and
4049
4054
not fullBarrier ( node ) and
4050
4055
not stateBarrier ( node , state ) and
4051
4056
not clearsContentEx ( node , ap .getHead ( ) .getContent ( ) ) and
@@ -4155,10 +4160,11 @@ module Impl<FullStateConfigSig Config> {
4155
4160
TSummaryCtx1 sc1 ;
4156
4161
TSummaryCtx2 sc2 ;
4157
4162
TSummaryCtx3 sc3 ;
4163
+ TSummaryCtx4 sc4 ;
4158
4164
DataFlowType t ;
4159
4165
PartialAccessPath ap ;
4160
4166
4161
- PartialPathNodeFwd ( ) { this = TPartialPathNodeFwd ( node , state , cc , sc1 , sc2 , sc3 , t , ap ) }
4167
+ PartialPathNodeFwd ( ) { this = TPartialPathNodeFwd ( node , state , cc , sc1 , sc2 , sc3 , sc4 , t , ap ) }
4162
4168
4163
4169
NodeEx getNodeEx ( ) { result = node }
4164
4170
@@ -4172,13 +4178,15 @@ module Impl<FullStateConfigSig Config> {
4172
4178
4173
4179
TSummaryCtx3 getSummaryCtx3 ( ) { result = sc3 }
4174
4180
4181
+ TSummaryCtx4 getSummaryCtx4 ( ) { result = sc4 }
4182
+
4175
4183
DataFlowType getType ( ) { result = t }
4176
4184
4177
4185
PartialAccessPath getAp ( ) { result = ap }
4178
4186
4179
4187
override PartialPathNodeFwd getASuccessor ( ) {
4180
4188
partialPathStep ( this , result .getNodeEx ( ) , result .getState ( ) , result .getCallContext ( ) ,
4181
- result .getSummaryCtx1 ( ) , result .getSummaryCtx2 ( ) , result .getSummaryCtx3 ( ) , result .getType ( ) , result .getAp ( ) )
4189
+ result .getSummaryCtx1 ( ) , result .getSummaryCtx2 ( ) , result .getSummaryCtx3 ( ) , result .getSummaryCtx4 ( ) , result . getType ( ) , result .getAp ( ) )
4182
4190
}
4183
4191
4184
4192
predicate isSource ( ) {
@@ -4187,6 +4195,7 @@ module Impl<FullStateConfigSig Config> {
4187
4195
sc1 = TSummaryCtx1None ( ) and
4188
4196
sc2 = TSummaryCtx2None ( ) and
4189
4197
sc3 = TSummaryCtx3None ( ) and
4198
+ sc4 = TSummaryCtx4None ( ) and
4190
4199
ap instanceof TPartialNil
4191
4200
}
4192
4201
}
@@ -4229,7 +4238,7 @@ module Impl<FullStateConfigSig Config> {
4229
4238
4230
4239
private predicate partialPathStep (
4231
4240
PartialPathNodeFwd mid , NodeEx node , FlowState state , CallContext cc , TSummaryCtx1 sc1 ,
4232
- TSummaryCtx2 sc2 , TSummaryCtx3 sc3 , DataFlowType t , PartialAccessPath ap
4241
+ TSummaryCtx2 sc2 , TSummaryCtx3 sc3 , TSummaryCtx4 sc4 , DataFlowType t , PartialAccessPath ap
4233
4242
) {
4234
4243
not isUnreachableInCallCached ( node .asNode ( ) , cc .( CallContextSpecificCall ) .getCall ( ) ) and
4235
4244
(
@@ -4239,6 +4248,7 @@ module Impl<FullStateConfigSig Config> {
4239
4248
sc1 = mid .getSummaryCtx1 ( ) and
4240
4249
sc2 = mid .getSummaryCtx2 ( ) and
4241
4250
sc3 = mid .getSummaryCtx3 ( ) and
4251
+ sc4 = mid .getSummaryCtx4 ( ) and
4242
4252
t = mid .getType ( ) and
4243
4253
ap = mid .getAp ( )
4244
4254
or
@@ -4248,6 +4258,7 @@ module Impl<FullStateConfigSig Config> {
4248
4258
sc1 = mid .getSummaryCtx1 ( ) and
4249
4259
sc2 = mid .getSummaryCtx2 ( ) and
4250
4260
sc3 = mid .getSummaryCtx3 ( ) and
4261
+ sc4 = mid .getSummaryCtx4 ( ) and
4251
4262
mid .getAp ( ) instanceof PartialAccessPathNil and
4252
4263
t = node .getDataFlowType ( ) and
4253
4264
ap = TPartialNil ( node .getDataFlowType ( ) )
@@ -4257,6 +4268,7 @@ module Impl<FullStateConfigSig Config> {
4257
4268
sc1 = mid .getSummaryCtx1 ( ) and
4258
4269
sc2 = mid .getSummaryCtx2 ( ) and
4259
4270
sc3 = mid .getSummaryCtx3 ( ) and
4271
+ sc4 = mid .getSummaryCtx4 ( ) and
4260
4272
mid .getAp ( ) instanceof PartialAccessPathNil and
4261
4273
t = node .getDataFlowType ( ) and
4262
4274
ap = TPartialNil ( node .getDataFlowType ( ) )
@@ -4268,7 +4280,8 @@ module Impl<FullStateConfigSig Config> {
4268
4280
sc1 = TSummaryCtx1None ( ) and
4269
4281
sc2 = TSummaryCtx2None ( ) and
4270
4282
sc3 = TSummaryCtx3None ( ) and
4271
- t = mid .getType ( ) and
4283
+ sc4 = TSummaryCtx4None ( ) and
4284
+ t = mid .getType ( ) and
4272
4285
ap = mid .getAp ( )
4273
4286
or
4274
4287
additionalJumpStep ( mid .getNodeEx ( ) , node ) and
@@ -4277,6 +4290,7 @@ module Impl<FullStateConfigSig Config> {
4277
4290
sc1 = TSummaryCtx1None ( ) and
4278
4291
sc2 = TSummaryCtx2None ( ) and
4279
4292
sc3 = TSummaryCtx3None ( ) and
4293
+ sc4 = TSummaryCtx4None ( ) and
4280
4294
mid .getAp ( ) instanceof PartialAccessPathNil and
4281
4295
t = node .getDataFlowType ( ) and
4282
4296
ap = TPartialNil ( node .getDataFlowType ( ) )
@@ -4286,6 +4300,7 @@ module Impl<FullStateConfigSig Config> {
4286
4300
sc1 = TSummaryCtx1None ( ) and
4287
4301
sc2 = TSummaryCtx2None ( ) and
4288
4302
sc3 = TSummaryCtx3None ( ) and
4303
+ sc4 = TSummaryCtx4None ( ) and
4289
4304
mid .getAp ( ) instanceof PartialAccessPathNil and
4290
4305
t = node .getDataFlowType ( ) and
4291
4306
ap = TPartialNil ( node .getDataFlowType ( ) )
@@ -4295,28 +4310,32 @@ module Impl<FullStateConfigSig Config> {
4295
4310
cc = mid .getCallContext ( ) and
4296
4311
sc1 = mid .getSummaryCtx1 ( ) and
4297
4312
sc2 = mid .getSummaryCtx2 ( ) and
4298
- sc3 = mid .getSummaryCtx3 ( )
4313
+ sc3 = mid .getSummaryCtx3 ( ) and
4314
+ sc4 = mid .getSummaryCtx4 ( )
4299
4315
or
4300
4316
exists ( DataFlowType t0 , PartialAccessPath ap0 , Content c |
4301
4317
partialPathReadStep ( mid , t0 , ap0 , c , node , cc ) and
4302
4318
state = mid .getState ( ) and
4303
4319
sc1 = mid .getSummaryCtx1 ( ) and
4304
4320
sc2 = mid .getSummaryCtx2 ( ) and
4305
4321
sc3 = mid .getSummaryCtx3 ( ) and
4322
+ sc4 = mid .getSummaryCtx4 ( ) and
4306
4323
apConsFwd ( t , ap , c , t0 , ap0 )
4307
4324
)
4308
4325
or
4309
- partialPathIntoCallable ( mid , node , state , _, cc , sc1 , sc2 , sc3 , _, t , ap )
4326
+ partialPathIntoCallable ( mid , node , state , _, cc , sc1 , sc2 , sc3 , sc4 , _, t , ap )
4310
4327
or
4311
4328
partialPathOutOfCallable ( mid , node , state , cc , t , ap ) and
4312
4329
sc1 = TSummaryCtx1None ( ) and
4313
4330
sc2 = TSummaryCtx2None ( ) and
4314
- sc3 = TSummaryCtx3None ( )
4331
+ sc3 = TSummaryCtx3None ( ) and
4332
+ sc4 = TSummaryCtx4None ( )
4315
4333
or
4316
4334
partialPathThroughCallable ( mid , node , state , cc , t , ap ) and
4317
4335
sc1 = mid .getSummaryCtx1 ( ) and
4318
4336
sc2 = mid .getSummaryCtx2 ( ) and
4319
- sc3 = mid .getSummaryCtx3 ( )
4337
+ sc3 = mid .getSummaryCtx3 ( ) and
4338
+ sc4 = mid .getSummaryCtx4 ( )
4320
4339
}
4321
4340
4322
4341
bindingset [ result , i]
@@ -4422,14 +4441,15 @@ module Impl<FullStateConfigSig Config> {
4422
4441
private predicate partialPathIntoCallable (
4423
4442
PartialPathNodeFwd mid , ParamNodeEx p , FlowState state , CallContext outercc ,
4424
4443
CallContextCall innercc , TSummaryCtx1 sc1 , TSummaryCtx2 sc2 , TSummaryCtx3 sc3 ,
4425
- DataFlowCall call , DataFlowType t , PartialAccessPath ap
4444
+ TSummaryCtx4 sc4 , DataFlowCall call , DataFlowType t , PartialAccessPath ap
4426
4445
) {
4427
4446
exists ( ParameterPosition pos , DataFlowCallable callable |
4428
4447
partialPathIntoCallable0 ( mid , callable , pos , state , outercc , call , t , ap ) and
4429
4448
p .isParameterOf ( callable , pos ) and
4430
4449
sc1 = TSummaryCtx1Param ( p ) and
4431
4450
sc2 = TSummaryCtx2Some ( state ) and
4432
- sc3 = TSummaryCtx3Some ( ap )
4451
+ sc3 = TSummaryCtx3Some ( t ) and
4452
+ sc4 = TSummaryCtx4Some ( ap )
4433
4453
|
4434
4454
if recordDataFlowCallSite ( call , callable )
4435
4455
then innercc = TSpecificCall ( call )
@@ -4440,7 +4460,7 @@ module Impl<FullStateConfigSig Config> {
4440
4460
pragma [ nomagic]
4441
4461
private predicate paramFlowsThroughInPartialPath (
4442
4462
ReturnKindExt kind , FlowState state , CallContextCall cc , TSummaryCtx1 sc1 , TSummaryCtx2 sc2 ,
4443
- TSummaryCtx3 sc3 , DataFlowType t , PartialAccessPath ap
4463
+ TSummaryCtx3 sc3 , TSummaryCtx4 sc4 , DataFlowType t , PartialAccessPath ap
4444
4464
) {
4445
4465
exists ( PartialPathNodeFwd mid , RetNodeEx ret |
4446
4466
mid .getNodeEx ( ) = ret and
@@ -4450,6 +4470,7 @@ module Impl<FullStateConfigSig Config> {
4450
4470
sc1 = mid .getSummaryCtx1 ( ) and
4451
4471
sc2 = mid .getSummaryCtx2 ( ) and
4452
4472
sc3 = mid .getSummaryCtx3 ( ) and
4473
+ sc4 = mid .getSummaryCtx4 ( ) and
4453
4474
t = mid .getType ( ) and
4454
4475
ap = mid .getAp ( )
4455
4476
)
@@ -4460,9 +4481,9 @@ module Impl<FullStateConfigSig Config> {
4460
4481
DataFlowCall call , PartialPathNodeFwd mid , ReturnKindExt kind , FlowState state ,
4461
4482
CallContext cc , DataFlowType t , PartialAccessPath ap
4462
4483
) {
4463
- exists ( CallContext innercc , TSummaryCtx1 sc1 , TSummaryCtx2 sc2 , TSummaryCtx3 sc3 |
4464
- partialPathIntoCallable ( mid , _, _, cc , innercc , sc1 , sc2 , sc3 , call , _, _) and
4465
- paramFlowsThroughInPartialPath ( kind , state , innercc , sc1 , sc2 , sc3 , t , ap )
4484
+ exists ( CallContext innercc , TSummaryCtx1 sc1 , TSummaryCtx2 sc2 , TSummaryCtx3 sc3 , TSummaryCtx4 sc4 |
4485
+ partialPathIntoCallable ( mid , _, _, cc , innercc , sc1 , sc2 , sc3 , sc4 , call , _, _) and
4486
+ paramFlowsThroughInPartialPath ( kind , state , innercc , sc1 , sc2 , sc3 , sc4 , t , ap )
4466
4487
)
4467
4488
}
4468
4489
0 commit comments