mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2026-06-02 07:41:33 +08:00
Merge remote-tracking branch 'origin/GP-5000_emteere_vxworksExtern' into patch
This commit is contained in:
@@ -4,9 +4,9 @@
|
|||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
* You may obtain a copy of the License at
|
* You may obtain a copy of the License at
|
||||||
*
|
*
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
*
|
*
|
||||||
* Unless required by applicable law or agreed to in writing, software
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
@@ -464,17 +464,17 @@ public class VxWorksSymTab_Finder extends GhidraScript {
|
|||||||
|
|
||||||
private boolean isValidSymType(byte symType) {
|
private boolean isValidSymType(byte symType) {
|
||||||
switch (symType) {
|
switch (symType) {
|
||||||
case 0: // Undefined Symbol
|
case 0: // Undefined Symbol
|
||||||
return false;
|
return false;
|
||||||
case 2: // Local Absolute
|
case 2: // Local Absolute
|
||||||
case 3: // Global Absolute
|
case 3: // Global Absolute
|
||||||
case 6: // Local Data
|
case 6: // Local Data
|
||||||
case 7: // Global Data
|
case 7: // Global Data
|
||||||
case 8: // Local BSS
|
case 8: // Local BSS
|
||||||
case 9: // Global BSS
|
case 9: // Global BSS
|
||||||
case 4: // Local .text
|
case 4: // Local .text
|
||||||
case 5: // Global .text
|
case 5: // Global .text
|
||||||
case 0x11: // External ref -- ignore
|
case 0x11: // External ref
|
||||||
return true;
|
return true;
|
||||||
default:
|
default:
|
||||||
return false;
|
return false;
|
||||||
@@ -815,18 +815,21 @@ public class VxWorksSymTab_Finder extends GhidraScript {
|
|||||||
println("NULL symType!");
|
println("NULL symType!");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 2: // Local Absolute
|
case 2: // Local Absolute
|
||||||
case 3: // Global Absolute
|
case 3: // Global Absolute
|
||||||
case 6: // Local Data
|
case 6: // Local Data
|
||||||
case 7: // Global Data
|
case 7: // Global Data
|
||||||
case 8: // Local BSS
|
case 8: // Local BSS
|
||||||
case 9: // Global BSS
|
case 9: // Global BSS
|
||||||
|
case 0x11: // External ref
|
||||||
|
|
||||||
createLabel(symLoc, symName, true);
|
createLabel(symLoc, symName, true);
|
||||||
applyDemangled(symLoc, symName, symDemangledName);
|
applyDemangled(symLoc, symName, symDemangledName);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 4: // Local .text
|
case 4: // Local .text
|
||||||
case 5: // Global .text
|
case 5: // Global .text
|
||||||
|
|
||||||
doLocalDisassemble(symLoc);
|
doLocalDisassemble(symLoc);
|
||||||
createFunction(symLoc, symName);
|
createFunction(symLoc, symName);
|
||||||
if (getFunctionAt(symLoc) != null) {
|
if (getFunctionAt(symLoc) != null) {
|
||||||
@@ -840,11 +843,8 @@ public class VxWorksSymTab_Finder extends GhidraScript {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x11: // External ref -- ignore
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
default:
|
||||||
println("Invalid symType!");
|
println("Invalid symType " + symType + " !");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user