Skip to content

Add some commands in Chapter 7.4#4107

Open
benquike wants to merge 1 commit intosecdev:masterfrom
benquike:7.4
Open

Add some commands in Chapter 7.4#4107
benquike wants to merge 1 commit intosecdev:masterfrom
benquike:7.4

Conversation

@benquike
Copy link
Copy Markdown
Contributor

Checklist:

  • If you are new to Scapy: I have checked CONTRIBUTING.md (esp. section submitting-pull-requests)
  • I squashed commits belonging together
  • I added unit tests or explained why they are not relevant
  • I executed the regression tests (using cd test && ./run_tests or tox)
  • If the PR is still not finished, please create a Draft Pull Request

fixes #xxx

@codecov
Copy link
Copy Markdown

codecov Bot commented Aug 31, 2023

Codecov Report

Merging #4107 (cc51514) into master (3e69007) will increase coverage by 0.38%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #4107      +/-   ##
==========================================
+ Coverage   81.59%   81.97%   +0.38%     
==========================================
  Files         328      328              
  Lines       75949    75958       +9     
==========================================
+ Hits        61968    62264     +296     
+ Misses      13981    13694     -287     
Files Changed Coverage Δ
scapy/layers/bluetooth.py 87.23% <100.00%> (+0.14%) ⬆️

... and 14 files with indirect coverage changes

@gpotter2
Copy link
Copy Markdown
Member

Thanks for the PR ! Could you add one (or more) unit tests? Thanks

@antoniovazquezblanco
Copy link
Copy Markdown
Contributor

Should this PR include some layer binding?

Comment thread scapy/layers/bluetooth.py
7.4.1 Read Local Version Information command

"""
name = "HCI_Read_Local_Version_Information"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This packets don't have a field_desc. Why are they useful for you?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because they set an opcode or ogf and ocf in the parent packet.

They are part of the Bluetooth specification and have a function.

Comment thread scapy/layers/bluetooth.py
# 7.4 INFORMATIONAL PARAMETERS, the OGF is defined as 0x04
class HCI_Cmd_Read_Local_Version_Information(Packet):
"""

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In previous PRs the class docstring was added but without newlines. Should the empty lines be removed?

Comment thread scapy/layers/bluetooth.py


# 7.4 INFORMATIONAL PARAMETERS, the OGF is defined as 0x04
class HCI_Cmd_Read_Local_Version_Information(Packet):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This packet is missing the corresponding binding.

Comment thread scapy/layers/bluetooth.py
name = "HCI_Read_Local_Version_Information"


class HCI_Cmd_Read_Local_Supported_Commands(Packet):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This packet is missing the corresponding binding.

Comment thread scapy/layers/bluetooth.py
name = "HCI_Read_Local_Supported_Commands"


class HCI_Cmd_Read_Local_Supported_Features(Packet):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This packet is missing the corresponding binding.

Comment thread scapy/layers/bluetooth.py
name = "HCI_Read_Local_Supported_Features"


class HCI_Cmd_Read_Local_Extended_Features(Packet):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This packet is missing the corresponding binding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants