diff --git a/LICENSE b/LICENSE new file mode 100644 index 000000000..be3f7b28e --- /dev/null +++ b/LICENSE @@ -0,0 +1,661 @@ + GNU AFFERO GENERAL PUBLIC LICENSE + Version 3, 19 November 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU Affero General Public License is a free, copyleft license for +software and other kinds of works, specifically designed to ensure +cooperation with the community in the case of network server software. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +our General Public Licenses are intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + Developers that use our General Public Licenses protect your rights +with two steps: (1) assert copyright on the software, and (2) offer +you this License which gives you legal permission to copy, distribute +and/or modify the software. + + A secondary benefit of defending all users' freedom is that +improvements made in alternate versions of the program, if they +receive widespread use, become available for other developers to +incorporate. Many developers of free software are heartened and +encouraged by the resulting cooperation. However, in the case of +software used on network servers, this result may fail to come about. +The GNU General Public License permits making a modified version and +letting the public access it on a server without ever releasing its +source code to the public. + + The GNU Affero General Public License is designed specifically to +ensure that, in such cases, the modified source code becomes available +to the community. It requires the operator of a network server to +provide the source code of the modified version running there to the +users of that server. Therefore, public use of a modified version, on +a publicly accessible server, gives the public access to the source +code of the modified version. + + An older license, called the Affero General Public License and +published by Affero, was designed to accomplish similar goals. This is +a different license, not a version of the Affero GPL, but Affero has +released a new version of the Affero GPL which permits relicensing under +this license. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU Affero General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Remote Network Interaction; Use with the GNU General Public License. + + Notwithstanding any other provision of this License, if you modify the +Program, your modified version must prominently offer all users +interacting with it remotely through a computer network (if your version +supports such interaction) an opportunity to receive the Corresponding +Source of your version by providing access to the Corresponding Source +from a network server at no charge, through some standard or customary +means of facilitating copying of software. This Corresponding Source +shall include the Corresponding Source for any work covered by version 3 +of the GNU General Public License that is incorporated pursuant to the +following paragraph. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the work with which it is combined will remain governed by version +3 of the GNU General Public License. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU Affero General Public License from time to time. Such new versions +will be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU Affero General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU Affero General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU Affero General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Affero General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU Affero General Public License for more details. + + You should have received a copy of the GNU Affero General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If your software can interact with users remotely through a computer +network, you should also make sure that it provides a way for users to +get its source. For example, if your program is a web application, its +interface could display a "Source" link that leads users to an archive +of the code. There are many ways you could offer source, and different +solutions will be better for different programs; see section 13 for the +specific requirements. + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU AGPL, see +. diff --git a/LICENSE.md b/LICENSE.md deleted file mode 100644 index c2d2752da..000000000 --- a/LICENSE.md +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2021 TC Developers - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/include/jsonrpccxx/batchclient.hpp b/include/jsonrpccxx/batchclient.hpp index 727fe05a9..7964861b3 100644 --- a/include/jsonrpccxx/batchclient.hpp +++ b/include/jsonrpccxx/batchclient.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "client.hpp" @@ -98,4 +99,4 @@ namespace jsonrpccxx { } } }; -} +} \ No newline at end of file diff --git a/include/jsonrpccxx/client.hpp b/include/jsonrpccxx/client.hpp index 3241d1591..d9f8f5c53 100644 --- a/include/jsonrpccxx/client.hpp +++ b/include/jsonrpccxx/client.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "common.hpp" #include "iclientconnector.hpp" @@ -89,4 +90,4 @@ namespace jsonrpccxx { connector.Send(j.dump()); } }; -} // namespace jsonrpccxx +} // namespace jsonrpccxx \ No newline at end of file diff --git a/include/jsonrpccxx/common.hpp b/include/jsonrpccxx/common.hpp index ccf12d240..646c090ac 100644 --- a/include/jsonrpccxx/common.hpp +++ b/include/jsonrpccxx/common.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include #include @@ -65,4 +66,4 @@ namespace jsonrpccxx { json data; std::string err; }; -} // namespace jsonrpccxx +} // namespace jsonrpccxx \ No newline at end of file diff --git a/include/jsonrpccxx/dispatcher.hpp b/include/jsonrpccxx/dispatcher.hpp index 35389b701..6485cd005 100644 --- a/include/jsonrpccxx/dispatcher.hpp +++ b/include/jsonrpccxx/dispatcher.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "common.hpp" @@ -103,4 +104,4 @@ namespace jsonrpccxx { throw JsonRpcException(invalid_request, "invalid request: params field must be an array, object"); } }; -} // namespace jsonrpccxx +} // namespace jsonrpccxx \ No newline at end of file diff --git a/include/jsonrpccxx/iclientconnector.hpp b/include/jsonrpccxx/iclientconnector.hpp index 23f1bef81..74db985b8 100644 --- a/include/jsonrpccxx/iclientconnector.hpp +++ b/include/jsonrpccxx/iclientconnector.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/include/jsonrpccxx/server.hpp b/include/jsonrpccxx/server.hpp index b404d5636..ce03e0c05 100644 --- a/include/jsonrpccxx/server.hpp +++ b/include/jsonrpccxx/server.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "common.hpp" @@ -111,4 +112,4 @@ namespace jsonrpccxx { } } }; -} +} \ No newline at end of file diff --git a/include/jsonrpccxx/typemapper.hpp b/include/jsonrpccxx/typemapper.hpp index b2ecbc57c..ba6655334 100644 --- a/include/jsonrpccxx/typemapper.hpp +++ b/include/jsonrpccxx/typemapper.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "common.hpp" @@ -197,4 +198,4 @@ namespace jsonrpccxx { }; return GetHandle(function); } -} +} \ No newline at end of file diff --git a/src/c2pool/bridge/legacy_tracker_bridge.cpp b/src/c2pool/bridge/legacy_tracker_bridge.cpp index f4b4bdabb..bdd415a99 100644 --- a/src/c2pool/bridge/legacy_tracker_bridge.cpp +++ b/src/c2pool/bridge/legacy_tracker_bridge.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "legacy_tracker_bridge.hpp" #include #include @@ -102,4 +103,4 @@ void LegacyShareTrackerBridge::convert_to_legacy_format(const C2PoolShare& share } } // namespace bridge -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/bridge/legacy_tracker_bridge.hpp b/src/c2pool/bridge/legacy_tracker_bridge.hpp index 9f439469e..f3d46d21f 100644 --- a/src/c2pool/bridge/legacy_tracker_bridge.hpp +++ b/src/c2pool/bridge/legacy_tracker_bridge.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -74,4 +75,4 @@ class LegacyShareTrackerBridge { }; } // namespace bridge -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/c2pool-qt.cpp b/src/c2pool/c2pool-qt.cpp index e69de29bb..64b955a0e 100644 --- a/src/c2pool/c2pool-qt.cpp +++ b/src/c2pool/c2pool-qt.cpp @@ -0,0 +1 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later diff --git a/src/c2pool/c2pool.cpp b/src/c2pool/c2pool.cpp index e69de29bb..64b955a0e 100644 --- a/src/c2pool/c2pool.cpp +++ b/src/c2pool/c2pool.cpp @@ -0,0 +1 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later diff --git a/src/c2pool/c2pool_node.cpp b/src/c2pool/c2pool_node.cpp index e69de29bb..64b955a0e 100644 --- a/src/c2pool/c2pool_node.cpp +++ b/src/c2pool/c2pool_node.cpp @@ -0,0 +1 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later diff --git a/src/c2pool/c2pool_refactored.cpp b/src/c2pool/c2pool_refactored.cpp index 631294447..be3604dd1 100644 --- a/src/c2pool/c2pool_refactored.cpp +++ b/src/c2pool/c2pool_refactored.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -7479,4 +7480,4 @@ int main(int argc, char* argv[]) { } return 0; -} +} \ No newline at end of file diff --git a/src/c2pool/c2pool_temp.cpp b/src/c2pool/c2pool_temp.cpp index e69de29bb..64b955a0e 100644 --- a/src/c2pool/c2pool_temp.cpp +++ b/src/c2pool/c2pool_temp.cpp @@ -0,0 +1 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later diff --git a/src/c2pool/difficulty/adjustment_engine.cpp b/src/c2pool/difficulty/adjustment_engine.cpp index 97a436cd4..02748b2f0 100644 --- a/src/c2pool/difficulty/adjustment_engine.cpp +++ b/src/c2pool/difficulty/adjustment_engine.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "adjustment_engine.hpp" #include #include @@ -158,4 +159,4 @@ void DifficultyAdjustmentEngine::adjust_pool_difficulty() { } } // namespace difficulty -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/difficulty/adjustment_engine.hpp b/src/c2pool/difficulty/adjustment_engine.hpp index 01f2acb6f..11aa6f8ec 100644 --- a/src/c2pool/difficulty/adjustment_engine.hpp +++ b/src/c2pool/difficulty/adjustment_engine.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -107,4 +108,4 @@ class DifficultyAdjustmentEngine { }; } // namespace difficulty -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/hashrate/tracker.cpp b/src/c2pool/hashrate/tracker.cpp index 8ed79b618..adf1b36ce 100644 --- a/src/c2pool/hashrate/tracker.cpp +++ b/src/c2pool/hashrate/tracker.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "tracker.hpp" #include #include @@ -197,4 +198,4 @@ void HashrateTracker::adjust_difficulty() { } } // namespace hashrate -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/hashrate/tracker.hpp b/src/c2pool/hashrate/tracker.hpp index 4ad242939..1cd7814d0 100644 --- a/src/c2pool/hashrate/tracker.hpp +++ b/src/c2pool/hashrate/tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -95,4 +96,4 @@ class HashrateTracker { }; } // namespace hashrate -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/ltc/ltc_coin_test.cpp b/src/c2pool/ltc/ltc_coin_test.cpp index ec9fabb0b..e5d541c53 100644 --- a/src/c2pool/ltc/ltc_coin_test.cpp +++ b/src/c2pool/ltc/ltc_coin_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include diff --git a/src/c2pool/ltc/ltc_pool_test.cpp b/src/c2pool/ltc/ltc_pool_test.cpp index 814f78e90..c544251a8 100644 --- a/src/c2pool/ltc/ltc_pool_test.cpp +++ b/src/c2pool/ltc/ltc_pool_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include diff --git a/src/c2pool/main_bch.cpp b/src/c2pool/main_bch.cpp index 17214b1d1..f5fc3d9f9 100644 --- a/src/c2pool/main_bch.cpp +++ b/src/c2pool/main_bch.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // c2pool-bch — Bitcoin Cash (BCH, SHA256d standalone parent, V36) p2pool node // entry point. // @@ -780,4 +781,4 @@ int main(int argc, char** argv) // Default / --selftest: drive the live ABLA budget path, then exit. return run_selftest(); -} +} \ No newline at end of file diff --git a/src/c2pool/main_btc.cpp b/src/c2pool/main_btc.cpp index ae2fedb27..e07e5102b 100644 --- a/src/c2pool/main_btc.cpp +++ b/src/c2pool/main_btc.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // c2pool-btc — Bitcoin embedded SPV p2pool node. // // PR-B2-net (focused header-sync entry point). @@ -1347,4 +1348,4 @@ int main(int argc, char* argv[]) p2p_node.reset(); LOG_INFO << "[BTC] Shutdown complete."; return 0; -} +} \ No newline at end of file diff --git a/src/c2pool/main_dash.cpp b/src/c2pool/main_dash.cpp index f0ab30415..4e3443df7 100644 --- a/src/c2pool/main_dash.cpp +++ b/src/c2pool/main_dash.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // c2pool-dash — DASH (X11 standalone parent, older-than-v35 -> V36) p2pool node // entry point. // @@ -558,4 +559,4 @@ int main(int argc, char** argv) return run_node(testnet, rpc_endpoint, rpc_conf_path, submit_hex, peer); } return run_selftest(); -} +} \ No newline at end of file diff --git a/src/c2pool/main_dgb.cpp b/src/c2pool/main_dgb.cpp index 21a6c0267..371cef78d 100644 --- a/src/c2pool/main_dgb.cpp +++ b/src/c2pool/main_dgb.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // c2pool-dgb — DigiByte Scrypt-only (V36) p2pool node entry point. // // Wires the real dgb sharechain/pool TU (pool pillars + score path, ported from @@ -1208,4 +1209,4 @@ int main(int argc, char** argv) // binary exercises real consensus code, then exit cleanly. (void)want_selftest; return run_selftest(params); -} +} \ No newline at end of file diff --git a/src/c2pool/merged/coin_broadcaster.hpp b/src/c2pool/merged/coin_broadcaster.hpp index 5616e434b..b87bd579b 100644 --- a/src/c2pool/merged/coin_broadcaster.hpp +++ b/src/c2pool/merged/coin_broadcaster.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Multi-peer P2P broadcaster for any Bitcoin-derived coin daemon. @@ -603,4 +604,4 @@ class CoinBroadcaster }; } // namespace merged -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/merged/coin_peer_manager.hpp b/src/c2pool/merged/coin_peer_manager.hpp index 388b7c4fb..a32362e7d 100644 --- a/src/c2pool/merged/coin_peer_manager.hpp +++ b/src/c2pool/merged/coin_peer_manager.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Multi-peer manager for coin daemon P2P connections. @@ -1060,4 +1061,4 @@ class CoinPeerManager }; } // namespace merged -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/merged/merged_mining.cpp b/src/c2pool/merged/merged_mining.cpp index 19556bb5a..385e71df9 100644 --- a/src/c2pool/merged/merged_mining.cpp +++ b/src/c2pool/merged/merged_mining.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "merged_mining.hpp" #include @@ -1742,4 +1743,4 @@ std::vector MergedMiningManager::get_chain_infos } } // namespace merged -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/merged/merged_mining.hpp b/src/c2pool/merged/merged_mining.hpp index a0e379649..360c96156 100644 --- a/src/c2pool/merged/merged_mining.hpp +++ b/src/c2pool/merged/merged_mining.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -438,4 +439,4 @@ class MergedMiningManager }; } // namespace merged -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/mining_share_tracker.cpp b/src/c2pool/mining_share_tracker.cpp index 403208aee..395757de5 100644 --- a/src/c2pool/mining_share_tracker.cpp +++ b/src/c2pool/mining_share_tracker.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "mining_share_tracker.hpp" namespace c2pool { @@ -5,4 +6,4 @@ namespace c2pool { // Implementation is header-only for now, but this file can be used // for future complex implementations that need to be in source files -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/mining_share_tracker.hpp b/src/c2pool/mining_share_tracker.hpp index 92b80a3eb..f54eaf43c 100644 --- a/src/c2pool/mining_share_tracker.hpp +++ b/src/c2pool/mining_share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "share_types.hpp" @@ -243,4 +244,4 @@ class MiningShareTracker { } }; -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/node/enhanced_node.hpp b/src/c2pool/node/enhanced_node.hpp index 40d3e0b93..f506076bc 100644 --- a/src/c2pool/node/enhanced_node.hpp +++ b/src/c2pool/node/enhanced_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Backward-compat header: resolves c2pool::node::EnhancedC2PoolNode to the @@ -15,4 +16,4 @@ namespace node { using EnhancedC2PoolNode = EnhancedC2PoolNodeT; } // namespace node -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/node/enhanced_node_impl.hpp b/src/c2pool/node/enhanced_node_impl.hpp index b85ddd5a1..e92e4397e 100644 --- a/src/c2pool/node/enhanced_node_impl.hpp +++ b/src/c2pool/node/enhanced_node_impl.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Coin-agnostic template for the enhanced c2pool node. @@ -235,4 +236,4 @@ class EnhancedC2PoolNodeT : public core::IMiningNode }; } // namespace node -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/p2p_share_tracker.cpp b/src/c2pool/p2p_share_tracker.cpp index 63179d8b5..c0f9de700 100644 --- a/src/c2pool/p2p_share_tracker.cpp +++ b/src/c2pool/p2p_share_tracker.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_share_tracker.hpp" namespace c2pool { @@ -5,4 +6,4 @@ namespace c2pool { // Implementation is header-only for now, but this file can be used // for future complex implementations that need to be in source files -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/p2p_share_tracker.hpp b/src/c2pool/p2p_share_tracker.hpp index 320913a60..290dce5de 100644 --- a/src/c2pool/p2p_share_tracker.hpp +++ b/src/c2pool/p2p_share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "share_types.hpp" @@ -268,4 +269,4 @@ class P2PShareTracker { } }; -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/payout/developer_payout.cpp b/src/c2pool/payout/developer_payout.cpp index 66251608d..f8cd02144 100644 --- a/src/c2pool/payout/developer_payout.cpp +++ b/src/c2pool/payout/developer_payout.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "developer_payout.hpp" #include #include @@ -333,4 +334,4 @@ bool PayoutManager::PayoutAllocation::is_valid() const { } } // namespace payout -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/payout/developer_payout.hpp b/src/c2pool/payout/developer_payout.hpp index b95ce174d..cc73a1441 100644 --- a/src/c2pool/payout/developer_payout.hpp +++ b/src/c2pool/payout/developer_payout.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -131,4 +132,4 @@ class PayoutManager { }; } // namespace payout -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/payout/payout_manager.cpp b/src/c2pool/payout/payout_manager.cpp index 793c51a0b..3eb346f93 100644 --- a/src/c2pool/payout/payout_manager.cpp +++ b/src/c2pool/payout/payout_manager.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "payout_manager.hpp" #include #include @@ -1299,4 +1300,4 @@ PayoutManager::calculate_pplns_outputs(uint64_t subsidy) const { } } // namespace payout -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/payout/payout_manager.hpp b/src/c2pool/payout/payout_manager.hpp index a5dfd0000..ba3de73dd 100644 --- a/src/c2pool/payout/payout_manager.hpp +++ b/src/c2pool/payout/payout_manager.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -248,4 +249,4 @@ class PayoutManager { }; } // namespace payout -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/share_types.hpp b/src/c2pool/share_types.hpp index 0f970e886..b0cbcede3 100644 --- a/src/c2pool/share_types.hpp +++ b/src/c2pool/share_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -192,4 +193,4 @@ struct ShareContainer { } }; -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/storage/found_block_store.hpp b/src/c2pool/storage/found_block_store.hpp index aef905425..fee5ad75e 100644 --- a/src/c2pool/storage/found_block_store.hpp +++ b/src/c2pool/storage/found_block_store.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -348,4 +349,4 @@ class MergedBlockStore { }; } // namespace storage -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/storage/sharechain_storage.cpp b/src/c2pool/storage/sharechain_storage.cpp index f5ec2c1cf..bc28849fc 100644 --- a/src/c2pool/storage/sharechain_storage.cpp +++ b/src/c2pool/storage/sharechain_storage.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "sharechain_storage.hpp" #include @@ -218,4 +219,4 @@ std::vector SharechainStorage::get_shares_by_height_range(uint64_t star // live in the header so any coin's ShareChain type gets implicit instantiation. } // namespace storage -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/storage/sharechain_storage.hpp b/src/c2pool/storage/sharechain_storage.hpp index d68ec8831..df4f6e03f 100644 --- a/src/c2pool/storage/sharechain_storage.hpp +++ b/src/c2pool/storage/sharechain_storage.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -228,4 +229,4 @@ class SharechainStorage { }; } // namespace storage -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/storage/the_checkpoint.hpp b/src/c2pool/storage/the_checkpoint.hpp index 2eb3c0c88..b38fa3593 100644 --- a/src/c2pool/storage/the_checkpoint.hpp +++ b/src/c2pool/storage/the_checkpoint.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // the_checkpoint.hpp — THE checkpoint verification and fast-sync support // @@ -280,4 +281,4 @@ class TheCheckpointStore { }; } // namespace storage -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/c2pool/test_ltc_node.cpp b/src/c2pool/test_ltc_node.cpp index a9ac64dd5..8a3cf0e43 100644 --- a/src/c2pool/test_ltc_node.cpp +++ b/src/c2pool/test_ltc_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Test program specifically for the LTC-based c2pool node #include #include @@ -179,4 +180,4 @@ int main() LOG_ERROR << "Test failed with exception: " << e.what(); return 1; } -} +} \ No newline at end of file diff --git a/src/core/address_utils.cpp b/src/core/address_utils.cpp index d543490b0..57849fffb 100644 --- a/src/core/address_utils.cpp +++ b/src/core/address_utils.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "address_utils.hpp" #include @@ -436,4 +437,4 @@ ScriptClassification classify_script(const std::vector& script, return classify_script(script, bech32_hrp, p2pkh_ver, p2sh_ver); } -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/address_utils.hpp b/src/core/address_utils.hpp index 4c26839c3..6902694d5 100644 --- a/src/core/address_utils.hpp +++ b/src/core/address_utils.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -85,4 +86,4 @@ ScriptClassification classify_script(const std::vector& script, /// Derive a P2PKH address from a raw compressed/uncompressed public key via Hash160. std::string pubkey_to_p2pkh_address(const unsigned char* pubkey, size_t len, uint8_t p2pkh_ver); -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/address_validator.cpp b/src/core/address_validator.cpp index c9a9b9dd5..922867746 100644 --- a/src/core/address_validator.cpp +++ b/src/core/address_validator.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "address_validator.hpp" #include #include @@ -641,4 +642,4 @@ std::string to_checksum_address(const std::string& eth_address) { } // namespace utils } // namespace address -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/core/address_validator.hpp b/src/core/address_validator.hpp index 165676f84..cc3a57458 100644 --- a/src/core/address_validator.hpp +++ b/src/core/address_validator.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -159,4 +160,4 @@ namespace utils { } } // namespace address -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/core/block_broadcast.hpp b/src/core/block_broadcast.hpp index e9a3a1832..d56d22c65 100644 --- a/src/core/block_broadcast.hpp +++ b/src/core/block_broadcast.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // block_broadcast.hpp — Cross-coin WON-block broadcast fallback orchestration @@ -68,4 +69,4 @@ inline bool broadcast_block_with_fallback( return false; // reached neither sink } -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/coin/block_bootstrapper.hpp b/src/core/coin/block_bootstrapper.hpp index 52d05f659..1530cab74 100644 --- a/src/core/coin/block_bootstrapper.hpp +++ b/src/core/coin/block_bootstrapper.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BlockBootstrapState: Ordered block download pipeline for UTXO cold-start sync. @@ -105,4 +106,4 @@ struct BlockBootstrapState { }; } // namespace coin -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/coin/node_iface.hpp b/src/core/coin/node_iface.hpp index 0cabd528a..1c0870c3c 100644 --- a/src/core/coin/node_iface.hpp +++ b/src/core/coin/node_iface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -61,4 +62,4 @@ struct ICoinNode { virtual bool has_rpc() const = 0; }; -} // namespace core::coin +} // namespace core::coin \ No newline at end of file diff --git a/src/core/coin_params.hpp b/src/core/coin_params.hpp index b8260d1d4..e5f4c68c4 100644 --- a/src/core/coin_params.hpp +++ b/src/core/coin_params.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // CoinParams: the "net" equivalent from Python p2pool. @@ -131,4 +132,4 @@ struct CoinParams } }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/coinbase_builder.hpp b/src/core/coinbase_builder.hpp index 1042e6f0e..15eeb468a 100644 --- a/src/core/coinbase_builder.hpp +++ b/src/core/coinbase_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // coinbase_builder.hpp — Coinbase scriptSig layout, THE metadata, space budget // @@ -291,4 +292,4 @@ struct ParsedScriptSig { } }; -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/core/config.hpp b/src/core/config.hpp index 3c760de61..445e78fa1 100644 --- a/src/core/config.hpp +++ b/src/core/config.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -45,4 +46,4 @@ class Config : public Pool, public Coin } }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/dns_seeder.hpp b/src/core/dns_seeder.hpp index b76740192..a9fb20455 100644 --- a/src/core/dns_seeder.hpp +++ b/src/core/dns_seeder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Async DNS seed resolver for Bitcoin-derived coin P2P networks. @@ -189,4 +190,4 @@ class DnsSeeder }; } // namespace dns -} // namespace c2pool +} // namespace c2pool \ No newline at end of file diff --git a/src/core/donation.hpp b/src/core/donation.hpp index 37db6b2f6..41f4926f0 100644 --- a/src/core/donation.hpp +++ b/src/core/donation.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // donation.hpp — Chain-agnostic c2pool donation script (SINGLE SOURCE OF TRUTH). @@ -63,4 +64,4 @@ inline std::vector get_donation_script(int64_t share_version) return {DONATION_SCRIPT.begin(), DONATION_SCRIPT.end()}; } -} // namespace core::donation +} // namespace core::donation \ No newline at end of file diff --git a/src/core/events.hpp b/src/core/events.hpp index 12662f770..5494c12e1 100644 --- a/src/core/events.hpp +++ b/src/core/events.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/core/events_legacy.hpp b/src/core/events_legacy.hpp index 1354fedef..4826d894e 100644 --- a/src/core/events_legacy.hpp +++ b/src/core/events_legacy.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/core/factory.hpp b/src/core/factory.hpp index 16cb7ac36..cafcd7ac8 100644 --- a/src/core/factory.hpp +++ b/src/core/factory.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include #include @@ -210,4 +211,4 @@ class Factory : public Components... } }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/fileconfig.hpp b/src/core/fileconfig.hpp index e88d110d6..aeebf6260 100644 --- a/src/core/fileconfig.hpp +++ b/src/core/fileconfig.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -57,4 +58,4 @@ class Fileconfig } }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/inetwork.hpp b/src/core/inetwork.hpp index 9b36b43f2..c33d3551e 100644 --- a/src/core/inetwork.hpp +++ b/src/core/inetwork.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -34,4 +35,4 @@ struct INetwork : public std::enable_shared_from_this virtual void disconnect() = 0; }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/mining_node_interface.hpp b/src/core/mining_node_interface.hpp index 925d75fe8..46e6be2e9 100644 --- a/src/core/mining_node_interface.hpp +++ b/src/core/mining_node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -33,4 +34,4 @@ class IMiningNode { virtual nlohmann::json get_stale_stats() const = 0; }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/node_interface.hpp b/src/core/node_interface.hpp index 9d6f1320f..7ae1c19fa 100644 --- a/src/core/node_interface.hpp +++ b/src/core/node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/core/reply_matcher.hpp b/src/core/reply_matcher.hpp index 46b046661..cb55e2c63 100644 --- a/src/core/reply_matcher.hpp +++ b/src/core/reply_matcher.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -161,4 +162,4 @@ struct ReplyMatcher template using ID = core::deffered::IdCreator; -}; +}; \ No newline at end of file diff --git a/src/core/settings.cpp b/src/core/settings.cpp index e3798d9f8..bf8ba65a1 100644 --- a/src/core/settings.cpp +++ b/src/core/settings.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "settings.hpp" #include diff --git a/src/core/settings.hpp b/src/core/settings.hpp index 574f70450..fcab9f787 100644 --- a/src/core/settings.hpp +++ b/src/core/settings.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/core/socket.cpp b/src/core/socket.cpp index ecd14cef8..c94423eaf 100644 --- a/src/core/socket.cpp +++ b/src/core/socket.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "socket.hpp" #include "factory.hpp" // INetwork complete definition for weak_ptr::lock() #include "log.hpp" @@ -247,4 +248,4 @@ void Socket::message_processing(std::shared_ptr packet) } -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/socket.hpp b/src/core/socket.hpp index bb1ddeb33..1d372ea41 100644 --- a/src/core/socket.hpp +++ b/src/core/socket.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -178,4 +179,4 @@ std::shared_ptr make_socket( std::move(weak_node), was_managed); } -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/stratum_server.cpp b/src/core/stratum_server.cpp index 1c57b4bb9..a979cbe1e 100644 --- a/src/core/stratum_server.cpp +++ b/src/core/stratum_server.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "stratum_server.hpp" #include "web_server.hpp" // MiningInterface #include "address_utils.hpp" // address utilities @@ -1575,5 +1576,4 @@ std::string StratumSession::generate_extranonce1() return ss.str(); } -} // namespace core - +} // namespace core \ No newline at end of file diff --git a/src/core/stratum_server.hpp b/src/core/stratum_server.hpp index 830798583..33f0f147d 100644 --- a/src/core/stratum_server.hpp +++ b/src/core/stratum_server.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -304,4 +305,4 @@ class StratumServer void handle_accept(boost::system::error_code ec, tcp::socket socket); }; -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/stratum_types.hpp b/src/core/stratum_types.hpp index 20cc84d38..987d1be06 100644 --- a/src/core/stratum_types.hpp +++ b/src/core/stratum_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Coin-agnostic data types crossing the stratum API boundary. @@ -137,4 +138,4 @@ struct WorkerInfo { std::string remote_endpoint; // "ip:port" }; -} // namespace core::stratum +} // namespace core::stratum \ No newline at end of file diff --git a/src/core/stratum_work_source.hpp b/src/core/stratum_work_source.hpp index 986f939ae..7a6bd6441 100644 --- a/src/core/stratum_work_source.hpp +++ b/src/core/stratum_work_source.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // IWorkSource — abstract interface that decouples `core::StratumServer` @@ -178,4 +179,4 @@ class IWorkSource { const std::vector& merkle_branches) const = 0; }; -} // namespace core::stratum +} // namespace core::stratum \ No newline at end of file diff --git a/src/core/test/block_broadcast_test.cpp b/src/core/test/block_broadcast_test.cpp index 344272f8c..e0615ce65 100644 --- a/src/core/test/block_broadcast_test.cpp +++ b/src/core/test/block_broadcast_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -82,4 +83,4 @@ TEST(CoreBlockBroadcast, NullSinks_NoCrash) EXPECT_FALSE(ok_neither) << "both sinks unavailable -> false, no crash"; } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/core/test/broadcast_convergence_matrix_test.cpp b/src/core/test/broadcast_convergence_matrix_test.cpp index 6ad878725..c3c4bb73a 100644 --- a/src/core/test/broadcast_convergence_matrix_test.cpp +++ b/src/core/test/broadcast_convergence_matrix_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // broadcast_convergence_matrix_test.cpp // @@ -184,4 +185,4 @@ TEST(BroadcastConvergenceMatrix, BchPolicyB_SinkAbsentIsNotSinkFailed) { EXPECT_TRUE(failed.p2p_sent); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/core/test/chain_test.cpp b/src/core/test/chain_test.cpp index 2724371b3..b5b5e7239 100644 --- a/src/core/test/chain_test.cpp +++ b/src/core/test/chain_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include diff --git a/src/core/test/core_merkle_branches_test.cpp b/src/core/test/core_merkle_branches_test.cpp index 1550aea72..2401b42ea 100644 --- a/src/core/test/core_merkle_branches_test.cpp +++ b/src/core/test/core_merkle_branches_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // core_merkle_branches_test.cpp // @@ -66,4 +67,4 @@ TEST(CoreMerkleBranches, EmptyAndSingleTxContract) { auto one = core::MiningInterface::compute_merkle_branches({TX1}); ASSERT_EQ(one.size(), 1u); EXPECT_EQ(one[0], internal_hex(TX1)); -} +} \ No newline at end of file diff --git a/src/core/test/events_test.cpp b/src/core/test/events_test.cpp index 66cee91f7..20d0cf9ae 100644 --- a/src/core/test/events_test.cpp +++ b/src/core/test/events_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -84,4 +85,4 @@ TEST(VariableTests, Transitioned_CarriesOldAndNew) v.set(2); EXPECT_EQ(old_val, 1); EXPECT_EQ(new_val, 2); -} +} \ No newline at end of file diff --git a/src/core/test/pack_test.cpp b/src/core/test/pack_test.cpp index 8fb70ba42..287702355 100644 --- a/src/core/test/pack_test.cpp +++ b/src/core/test/pack_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include diff --git a/src/core/test/packet_test.cpp b/src/core/test/packet_test.cpp index 5b5e5f6d6..ec2e81231 100644 --- a/src/core/test/packet_test.cpp +++ b/src/core/test/packet_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -61,4 +62,4 @@ TEST(PacketPrefixCap, UafGarbageMaxSizeThrows) std::ios_base::failure); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/core/test/version_gate_test.cpp b/src/core/test/version_gate_test.cpp index c43673a75..e1d2a38a3 100644 --- a/src/core/test/version_gate_test.cpp +++ b/src/core/test/version_gate_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -106,4 +107,4 @@ TEST(VersionGateTransition, ExactSixtyPercentBoundaryAdmitted) // 60*100 == 100*60, NOT strictly less -> 60% PASSES (no throw). auto w = tally({{36, 60}, {35, 40}}); // total 100, new=60 -> exactly 60% EXPECT_NO_THROW(verify_version_transition(35, 36, w, /*have_history=*/true)); -} +} \ No newline at end of file diff --git a/src/core/web_server.cpp b/src/core/web_server.cpp index da30f33c6..434dacead 100644 --- a/src/core/web_server.cpp +++ b/src/core/web_server.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "web_server.hpp" #include "stratum_server.hpp" #include @@ -8956,4 +8957,4 @@ double MiningInterface::calculate_share_difficulty( return truediffone / hash_val; } -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/core/web_server.hpp b/src/core/web_server.hpp index b3a4e9532..924ab3cb9 100644 --- a/src/core/web_server.hpp +++ b/src/core/web_server.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -1577,4 +1578,4 @@ class WebServer // StratumSession and StratumServer — see stratum_server.hpp -} // namespace core +} // namespace core \ No newline at end of file diff --git a/src/impl/bch/coin/abla.hpp b/src/impl/bch/coin/abla.hpp index 5c3f2e0f6..20e1bdf8b 100644 --- a/src/impl/bch/coin/abla.hpp +++ b/src/impl/bch/coin/abla.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH ABLA (Adaptive Blocksize-Limit Algorithm, CHIP-2023-01) -- net-new // BCH-specific code. Activated at the May 2024 upgrade; it replaces the static @@ -211,4 +212,4 @@ inline uint64_t floor_block_size_limit(bool is_testnet) { } // namespace abla } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/abla_block_feed.hpp b/src/impl/bch/coin/abla_block_feed.hpp index 9d10bc52e..e5305eb29 100644 --- a/src/impl/bch/coin/abla_block_feed.hpp +++ b/src/impl/bch/coin/abla_block_feed.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::AblaBlockFeed -- M5: drives the ABLA size feed from the REAL @@ -133,4 +134,4 @@ class AblaBlockFeed { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/abla_runtime.hpp b/src/impl/bch/coin/abla_runtime.hpp index 22db07218..cc7cbafad 100644 --- a/src/impl/bch/coin/abla_runtime.hpp +++ b/src/impl/bch/coin/abla_runtime.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::AblaRuntime -- M5: the CLOSING assembly of the embedded-daemon @@ -97,4 +98,4 @@ class AblaRuntime { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/abla_tracker.hpp b/src/impl/bch/coin/abla_tracker.hpp index f550d1d5c..1e9e4e587 100644 --- a/src/impl/bch/coin/abla_tracker.hpp +++ b/src/impl/bch/coin/abla_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH ABLA size-feed tracker (CHIP-2023-01) -- M5 slice C. // @@ -138,4 +139,4 @@ class AblaTracker { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/asert.hpp b/src/impl/bch/coin/asert.hpp index 837ea129a..c9397c075 100644 --- a/src/impl/bch/coin/asert.hpp +++ b/src/impl/bch/coin/asert.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH ASERT (aserti3-2d) difficulty adjustment — net-new BCH-specific code. // @@ -216,4 +217,4 @@ inline uint32_t get_next_work_required_asert(uint32_t tip_height, } } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/bchn_anchor_record.hpp b/src/impl/bch/coin/bchn_anchor_record.hpp index 5c9ab37ed..5db99c6c0 100644 --- a/src/impl/bch/coin/bchn_anchor_record.hpp +++ b/src/impl/bch/coin/bchn_anchor_record.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCHN cold-start anchor record (VM300 bchn-bch, operator-approved read-only @@ -68,4 +69,4 @@ struct BchnAnchorRecord { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/block.hpp b/src/impl/bch/coin/block.hpp index c7bfea761..fad27f073 100644 --- a/src/impl/bch/coin/block.hpp +++ b/src/impl/bch/coin/block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "transaction.hpp" @@ -133,4 +134,4 @@ struct BlockType : BlockHeaderType } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/block_broadcast_guard.hpp b/src/impl/bch/coin/block_broadcast_guard.hpp index 676520881..eb8182e77 100644 --- a/src/impl/bch/coin/block_broadcast_guard.hpp +++ b/src/impl/bch/coin/block_broadcast_guard.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin -- guarded dual-path won-block broadcast. // @@ -88,4 +89,4 @@ inline BlockBroadcast guarded_dual_broadcast(bool have_p2p, P2PRelayFn&& p2p_rel } } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/block_connector.hpp b/src/impl/bch/coin/block_connector.hpp index 3d700da57..22bc9eaa6 100644 --- a/src/impl/bch/coin/block_connector.hpp +++ b/src/impl/bch/coin/block_connector.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::BlockConnector -- M5 full-block body. @@ -374,4 +375,4 @@ class BlockConnector { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/block_download.hpp b/src/impl/bch/coin/block_download.hpp index ca2eff2c5..c62d1ead6 100644 --- a/src/impl/bch/coin/block_download.hpp +++ b/src/impl/bch/coin/block_download.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::block_download -- M5 full-block body. Windowed headers-first block @@ -237,4 +238,4 @@ class BlockDownloadWindow { std::unordered_map m_rejects; // hash -> reject attempts }; -} // namespace bch::coin::block_download +} // namespace bch::coin::block_download \ No newline at end of file diff --git a/src/impl/bch/coin/cashaddr.hpp b/src/impl/bch/coin/cashaddr.hpp index 33a4148bf..8965df921 100644 --- a/src/impl/bch/coin/cashaddr.hpp +++ b/src/impl/bch/coin/cashaddr.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::cashaddr -- BCH CashAddr address codec (M4 TODO from config_coin.hpp). @@ -342,4 +343,4 @@ inline void register_cashaddr_decoder(bool testnet, bool regtest) { } // namespace cashaddr } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/chain_seeds.hpp b/src/impl/bch/coin/chain_seeds.hpp index 42f992e99..1534ae19a 100644 --- a/src/impl/bch/coin/chain_seeds.hpp +++ b/src/impl/bch/coin/chain_seeds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DNS seed hostnames and hardcoded fallback IPs for Bitcoin Cash P2P networks. @@ -107,4 +108,4 @@ inline std::vector bch_fixed_seeds(bool testnet) } } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/coin_node.cpp b/src/impl/bch/coin/coin_node.cpp index ece6bbcf7..082ae6edc 100644 --- a/src/impl/bch/coin/coin_node.cpp +++ b/src/impl/bch/coin/coin_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "coin_node.hpp" #include @@ -47,4 +48,4 @@ bool CoinNode::submit_block_hex(const std::string& block_hex, bool ignore_failur } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/coin_node.hpp b/src/impl/bch/coin/coin_node.hpp index b35db9fe9..ca44d6d84 100644 --- a/src/impl/bch/coin/coin_node.hpp +++ b/src/impl/bch/coin/coin_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -59,4 +60,4 @@ class CoinNode : public core::coin::ICoinNode } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/compact_blocks.hpp b/src/impl/bch/coin/compact_blocks.hpp index 79a969e4d..bafca0613 100644 --- a/src/impl/bch/coin/compact_blocks.hpp +++ b/src/impl/bch/coin/compact_blocks.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BIP 152 Compact Block Support -- ported from src/impl/btc/coin/compact_blocks.hpp. @@ -329,4 +330,4 @@ inline CompactBlockReconstructionResult ReconstructBlock( } } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/embedded_daemon.hpp b/src/impl/bch/coin/embedded_daemon.hpp index de85d83b5..8c60b56a5 100644 --- a/src/impl/bch/coin/embedded_daemon.hpp +++ b/src/impl/bch/coin/embedded_daemon.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::EmbeddedDaemon -- M5: the embedded-daemon ENTRYPOINT @@ -569,4 +570,4 @@ class EmbeddedDaemon { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/header_chain.hpp b/src/impl/bch/coin/header_chain.hpp index c363534ac..82381f8d0 100644 --- a/src/impl/bch/coin/header_chain.hpp +++ b/src/impl/bch/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BCH Header Chain @@ -1142,4 +1143,4 @@ class HeaderChain { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/header_sync.hpp b/src/impl/bch/coin/header_sync.hpp index 396567e96..cdb55c9c0 100644 --- a/src/impl/bch/coin/header_sync.hpp +++ b/src/impl/bch/coin/header_sync.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin::header_sync -- M5 full-block body. Headers-first IBD continuation @@ -88,4 +89,4 @@ inline std::vector choose_continue_locator( return {last_hash}; } -} // namespace bch::coin::header_sync +} // namespace bch::coin::header_sync \ No newline at end of file diff --git a/src/impl/bch/coin/mempool.hpp b/src/impl/bch/coin/mempool.hpp index 68e4a7b46..d7b5f06bb 100644 --- a/src/impl/bch/coin/mempool.hpp +++ b/src/impl/bch/coin/mempool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BCH Mempool — Phase 2 + UTXO fee computation @@ -755,4 +756,4 @@ class Mempool { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/merkle.hpp b/src/impl/bch/coin/merkle.hpp index 0bf757874..1ba75aaf7 100644 --- a/src/impl/bch/coin/merkle.hpp +++ b/src/impl/bch/coin/merkle.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // bch::coin merkle helpers -- single source of truth for the SHA256d @@ -52,4 +53,4 @@ inline uint256 compute_merkle_root(std::vector hashes) { } } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/node.hpp b/src/impl/bch/coin/node.hpp index c816b441e..8eab5fb9c 100644 --- a/src/impl/bch/coin/node.hpp +++ b/src/impl/bch/coin/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -157,4 +158,4 @@ class Node : public bch::interfaces::Node } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/node_interface.hpp b/src/impl/bch/coin/node_interface.hpp index 4710c97a9..32a34a537 100644 --- a/src/impl/bch/coin/node_interface.hpp +++ b/src/impl/bch/coin/node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -46,4 +47,4 @@ struct Node } // namespace interfaces -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/p2p_connection.cpp b/src/impl/bch/coin/p2p_connection.cpp index a85bfbfae..9e7b820fa 100644 --- a/src/impl/bch/coin/p2p_connection.cpp +++ b/src/impl/bch/coin/p2p_connection.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_connection.hpp" namespace bch @@ -37,4 +38,4 @@ void Connection::get_header(uint256 id, BlockHeaderType response) } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/p2p_connection.hpp b/src/impl/bch/coin/p2p_connection.hpp index c7b4ee15f..ddb560344 100644 --- a/src/impl/bch/coin/p2p_connection.hpp +++ b/src/impl/bch/coin/p2p_connection.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH p2p Connection (M3 slice 11) — per-peer request/reply matcher + socket @@ -94,4 +95,4 @@ class Connection } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/p2p_messages.hpp b/src/impl/bch/coin/p2p_messages.hpp index 874da7790..c0235b446 100644 --- a/src/impl/bch/coin/p2p_messages.hpp +++ b/src/impl/bch/coin/p2p_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH P2P wire messages (M3 slice 7). @@ -398,4 +399,4 @@ using Handler = MessageHandler< } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/p2p_node.cpp b/src/impl/bch/coin/p2p_node.cpp index 3809d6099..7009b107c 100644 --- a/src/impl/bch/coin/p2p_node.cpp +++ b/src/impl/bch/coin/p2p_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_node.hpp" namespace bch @@ -23,4 +24,4 @@ std::string parse_net_error(const boost::system::error_code& ec) } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/p2p_node.hpp b/src/impl/bch/coin/p2p_node.hpp index d89b21893..2f0a8ef5b 100644 --- a/src/impl/bch/coin/p2p_node.hpp +++ b/src/impl/bch/coin/p2p_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -1199,4 +1200,4 @@ class NodeP2P : public core::ICommunicator, public core::INetwork, public core:: } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/regtest_block.hpp b/src/impl/bch/coin/regtest_block.hpp index c2fa99bd8..cc9dc4ed0 100644 --- a/src/impl/bch/coin/regtest_block.hpp +++ b/src/impl/bch/coin/regtest_block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // regtest_block.hpp -- valid-block construction for the leg-C broadcaster-gate @@ -181,4 +182,4 @@ inline BuiltBlock build_from_gbt(const nlohmann::json& tmpl, uint64_t extranonce } // namespace regtest } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/rpc.cpp b/src/impl/bch/coin/rpc.cpp index 0c35efaef..b22d82059 100644 --- a/src/impl/bch/coin/rpc.cpp +++ b/src/impl/bch/coin/rpc.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "rpc.hpp" #include @@ -464,4 +465,4 @@ nlohmann::json NodeRPC::getblock(uint256 blockhash, int verbosity) } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/rpc.hpp b/src/impl/bch/coin/rpc.hpp index b56a91dd7..c11d5d8ff 100644 --- a/src/impl/bch/coin/rpc.hpp +++ b/src/impl/bch/coin/rpc.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -107,4 +108,4 @@ struct RPCAuthData } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/rpc_data.hpp b/src/impl/bch/coin/rpc_data.hpp index 8eda87548..18a53f36f 100644 --- a/src/impl/bch/coin/rpc_data.hpp +++ b/src/impl/bch/coin/rpc_data.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -48,4 +49,4 @@ struct WorkData } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/softfork_check.hpp b/src/impl/bch/coin/softfork_check.hpp index 091abaf3b..954bca5e4 100644 --- a/src/impl/bch/coin/softfork_check.hpp +++ b/src/impl/bch/coin/softfork_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -42,4 +43,4 @@ inline void collect_softfork_names(const nlohmann::json& value, } } -} // namespace bch::coin +} // namespace bch::coin \ No newline at end of file diff --git a/src/impl/bch/coin/template_builder.hpp b/src/impl/bch/coin/template_builder.hpp index 174673e52..6eb2b82ab 100644 --- a/src/impl/bch/coin/template_builder.hpp +++ b/src/impl/bch/coin/template_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH block-template builder. Mirrors src/impl/btc/coin/template_builder.hpp, // diverging where BCH consensus requires (M1 §4): @@ -335,4 +336,4 @@ class EmbeddedCoinNode : public CoinNodeInterface { }; } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/transaction.cpp b/src/impl/bch/coin/transaction.cpp index 4c19a9bfb..08ae239a0 100644 --- a/src/impl/bch/coin/transaction.cpp +++ b/src/impl/bch/coin/transaction.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "transaction.hpp" // bch::coin transaction ctors -- ported from src/impl/btc/coin/transaction.cpp. @@ -21,4 +22,4 @@ MutableTransaction::MutableTransaction(const Transaction& tx) } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/transaction.hpp b/src/impl/bch/coin/transaction.hpp index 71deb38f8..7819be44d 100644 --- a/src/impl/bch/coin/transaction.hpp +++ b/src/impl/bch/coin/transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -132,4 +133,4 @@ void SerializeTransaction(const TxType& tx, StreamType& s) } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coin/txidcache.hpp b/src/impl/bch/coin/txidcache.hpp index 43b29961a..20f03d9e4 100644 --- a/src/impl/bch/coin/txidcache.hpp +++ b/src/impl/bch/coin/txidcache.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -88,4 +89,4 @@ class TXIDCache } // namespace coin -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/coinbase_commitment.hpp b/src/impl/bch/coinbase_commitment.hpp index 472c9da7e..2a0a1cf38 100644 --- a/src/impl/bch/coinbase_commitment.hpp +++ b/src/impl/bch/coinbase_commitment.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // coinbase_commitment.hpp -- Coinbase / template commitment construction and @@ -224,4 +225,4 @@ inline CommitmentValidationResult validate_coinbase_commitment( return r; } -} // namespace bch::consensus +} // namespace bch::consensus \ No newline at end of file diff --git a/src/impl/bch/config.hpp b/src/impl/bch/config.hpp index 30b5607e2..2631cc542 100644 --- a/src/impl/bch/config.hpp +++ b/src/impl/bch/config.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // bch::Config -- BCH coin+pool config aggregator. Ported from // src/impl/btc/config.hpp (M3 slice 14). Binds the BCH PoolConfig (sharechain @@ -13,4 +14,4 @@ namespace bch using Config = core::Config; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/config_coin.cpp b/src/impl/bch/config_coin.cpp index eeb992bea..731976e44 100644 --- a/src/impl/bch/config_coin.cpp +++ b/src/impl/bch/config_coin.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_coin.hpp" #include @@ -36,4 +37,4 @@ void CoinConfig::load() PARSE_CONFIG(node, testnet, bool); } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/config_coin.hpp b/src/impl/bch/config_coin.hpp index 0478101d1..ce65d339f 100644 --- a/src/impl/bch/config_coin.hpp +++ b/src/impl/bch/config_coin.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // bch::CoinConfig -- BCH coin parameters (V36). Ported from // src/impl/btc/config_coin.hpp (M3 slice 14). Namespace bch (was the M2 @@ -109,4 +110,4 @@ class CoinConfig : protected core::Fileconfig bool m_testnet4 {false}; // BCH testnet4: OWN genesis (000000001dd4..) + magic e2b7daaf; testnet-class for ABLA/ASERT }; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/config_pool.cpp b/src/impl/bch/config_pool.cpp index 02b4edb32..7bbb6165a 100644 --- a/src/impl/bch/config_pool.cpp +++ b/src/impl/bch/config_pool.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_pool.hpp" #include @@ -45,4 +46,4 @@ void PoolConfig::load() } } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/config_pool.hpp b/src/impl/bch/config_pool.hpp index c0d5c4819..9b5149725 100644 --- a/src/impl/bch/config_pool.hpp +++ b/src/impl/bch/config_pool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -265,4 +266,4 @@ class PoolConfig : protected core::Fileconfig std::vector m_bootstrap_addrs; }; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/donation_consensus.hpp b/src/impl/bch/donation_consensus.hpp index 2e3a47c60..a8a0a1709 100644 --- a/src/impl/bch/donation_consensus.hpp +++ b/src/impl/bch/donation_consensus.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // donation_consensus.hpp -- Consensus-level donation script validation for BCH @@ -117,4 +118,4 @@ inline DonationValidationResult validate_coinbase_total( return {true, {}}; } -} // namespace bch::consensus +} // namespace bch::consensus \ No newline at end of file diff --git a/src/impl/bch/messages.hpp b/src/impl/bch/messages.hpp index b37a00f03..78ce61b65 100644 --- a/src/impl/bch/messages.hpp +++ b/src/impl/bch/messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH share/pool p2p protocol messages. @@ -199,4 +200,4 @@ using Handler = MessageHandler< message_remember_tx >; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/node.cpp b/src/impl/bch/node.cpp index 989be4666..5cd6fa382 100644 --- a/src/impl/bch/node.cpp +++ b/src/impl/bch/node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include @@ -2419,4 +2420,4 @@ void NodeImpl::set_rss_limit_mb(long mb) g_rss_limit_mb = mb; } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/node.hpp b/src/impl/bch/node.hpp index cb79a7379..fcca00300 100644 --- a/src/impl/bch/node.hpp +++ b/src/impl/bch/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH share/pool p2p node (NodeImpl / pool::BaseNode declaration). @@ -869,4 +870,4 @@ class Actual : public pool::Protocol using Node = pool::NodeBridge; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/peer.hpp b/src/impl/bch/peer.hpp index 9cc4a4ebd..4fb6382fd 100644 --- a/src/impl/bch/peer.hpp +++ b/src/impl/bch/peer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/transaction.hpp" @@ -28,4 +29,4 @@ struct Peer std::map m_remembered_txs; }; -}; // namespace bch +}; // namespace bch \ No newline at end of file diff --git a/src/impl/bch/pool_entrypoint.hpp b/src/impl/bch/pool_entrypoint.hpp index 4bf0888e7..36b23b5ad 100644 --- a/src/impl/bch/pool_entrypoint.hpp +++ b/src/impl/bch/pool_entrypoint.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH pool run-loop ENTRYPOINT standup -- broadcaster-gate leg C, pool side @@ -600,4 +601,4 @@ inline void standup_pool_run(boost::asio::io_context& ioc, ioc.run(); } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/pool_monitor.hpp b/src/impl/bch/pool_monitor.hpp index 259d8ee97..5bd322440 100644 --- a/src/impl/bch/pool_monitor.hpp +++ b/src/impl/bch/pool_monitor.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 3L: Log-based pool monitoring for attack detection. @@ -366,4 +367,4 @@ class PoolMonitor } }; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/pool_standup.hpp b/src/impl/bch/pool_standup.hpp index 4b3039c7a..e14e35963 100644 --- a/src/impl/bch/pool_standup.hpp +++ b/src/impl/bch/pool_standup.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // BCH pool-node won-block sink standup -- broadcaster-gate leg C, pool-entrypoint @@ -43,4 +44,4 @@ inline void wire_won_block_sink(NodeImpl& node, coin::EmbeddedDaemon& da }); } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/protocol_actual.cpp b/src/impl/bch/protocol_actual.cpp index cd70fa3d6..d4716912f 100644 --- a/src/impl/bch/protocol_actual.cpp +++ b/src/impl/bch/protocol_actual.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // BCH actual-protocol dispatch router + HANDLER cluster (broadcaster-gate / // pool p2p ingress). // @@ -320,4 +321,4 @@ void Actual::HANDLER(forget_tx) } } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/protocol_legacy.cpp b/src/impl/bch/protocol_legacy.cpp index 1b215895d..06ff6399c 100644 --- a/src/impl/bch/protocol_legacy.cpp +++ b/src/impl/bch/protocol_legacy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // BCH legacy-protocol dispatch router (broadcaster-gate / pool p2p ingress). // // Mirror of btc::Legacy::handle_message with the namespace swapped to bch. @@ -337,4 +338,4 @@ void Legacy::HANDLER(forget_tx) } } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/share.hpp b/src/impl/bch/share.hpp index dc07bf48a..511bb7625 100644 --- a/src/impl/bch/share.hpp +++ b/src/impl/bch/share.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/block.hpp" @@ -313,5 +314,4 @@ struct ShareChain : chain::ShareChain }; -} // namespace bch - +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/share_check.hpp b/src/impl/bch/share_check.hpp index b1bea105c..f3fea9b2a 100644 --- a/src/impl/bch/share_check.hpp +++ b/src/impl/bch/share_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // P2: Share verification — check_hash_link, check_merkle_link, share init/check @@ -3407,4 +3408,4 @@ uint256 create_local_share( return share_hash; } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/share_messages.hpp b/src/impl/bch/share_messages.hpp index 701c34901..1afcb2740 100644 --- a/src/impl/bch/share_messages.hpp +++ b/src/impl/bch/share_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // share_messages.hpp — V36 share-embedded messaging: decryption + validation // // Port of p2pool/share_messages.py (consensus-critical portions). @@ -576,4 +577,4 @@ inline std::vector create_message_data( return encrypt_message_envelope(inner, authority_pubkey); } -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/share_tracker.hpp b/src/impl/bch/share_tracker.hpp index 9ad13a62e..94dafc0e6 100644 --- a/src/impl/bch/share_tracker.hpp +++ b/src/impl/bch/share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // share_tracker.hpp -- BCH PPLNS / expected-payouts engine (M3 slice 16). @@ -2034,4 +2035,4 @@ class ShareTracker } }; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/share_types.hpp b/src/impl/bch/share_types.hpp index 32a49054e..f10c72c1e 100644 --- a/src/impl/bch/share_types.hpp +++ b/src/impl/bch/share_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -202,4 +203,4 @@ struct AbsworkV36Format } }; -} // namespace bch +} // namespace bch \ No newline at end of file diff --git a/src/impl/bch/stratum/coinbase_outputs.hpp b/src/impl/bch/stratum/coinbase_outputs.hpp index dbe0f7b25..21b6751aa 100644 --- a/src/impl/bch/stratum/coinbase_outputs.hpp +++ b/src/impl/bch/stratum/coinbase_outputs.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // bch::stratum::assemble_v36_coinbase_outputs // @@ -172,4 +173,4 @@ inline void apply_v35_finder_fee( } } -} // namespace bch::stratum +} // namespace bch::stratum \ No newline at end of file diff --git a/src/impl/bch/stratum/work_source.cpp b/src/impl/bch/stratum/work_source.cpp index 1c5627ef2..b6af4333c 100644 --- a/src/impl/bch/stratum/work_source.cpp +++ b/src/impl/bch/stratum/work_source.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // bch::stratum::BCHWorkSource — slice-c implementation. // // Implements the read-only state accessors, per-connection worker @@ -772,4 +773,4 @@ double BCHWorkSource::compute_share_difficulty( return chain::target_to_difficulty(pow_hash); } -} // namespace bch::stratum +} // namespace bch::stratum \ No newline at end of file diff --git a/src/impl/bch/stratum/work_source.hpp b/src/impl/bch/stratum/work_source.hpp index bd506a291..05ec52209 100644 --- a/src/impl/bch/stratum/work_source.hpp +++ b/src/impl/bch/stratum/work_source.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // bch::stratum::BCHWorkSource — concrete `core::stratum::IWorkSource` @@ -303,4 +304,4 @@ class BCHWorkSource : public core::stratum::IWorkSource std::shared_ptr cached_template() const; }; -} // namespace bch::stratum +} // namespace bch::stratum \ No newline at end of file diff --git a/src/impl/bch/test/abla_block_feed_gap_test.cpp b/src/impl/bch/test/abla_block_feed_gap_test.cpp index fa3fe0606..4fa6fa88f 100644 --- a/src/impl/bch/test/abla_block_feed_gap_test.cpp +++ b/src/impl/bch/test/abla_block_feed_gap_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin AblaBlockFeed GAP/never-undercut test (M5 -- full-block -> ABLA). // @@ -143,4 +144,4 @@ int main() { } std::cerr << "abla_block_feed_gap_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/abla_block_feed_test.cpp b/src/impl/bch/test/abla_block_feed_test.cpp index 3a9d450fb..ea941cd93 100644 --- a/src/impl/bch/test/abla_block_feed_test.cpp +++ b/src/impl/bch/test/abla_block_feed_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin AblaBlockFeed test (M5 -- the full-block -> ABLA wiring layer). // @@ -127,4 +128,4 @@ int main() { } std::cerr << "abla_block_feed_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/abla_floor_invariant_test.cpp b/src/impl/bch/test/abla_floor_invariant_test.cpp index bacbf039f..c11625150 100644 --- a/src/impl/bch/test/abla_floor_invariant_test.cpp +++ b/src/impl/bch/test/abla_floor_invariant_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::abla AblaTracker floor-invariant test (M5 cold-start safety). // @@ -96,4 +97,4 @@ int main() { } std::cerr << "abla_floor_invariant_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/abla_growth_soak_test.cpp b/src/impl/bch/test/abla_growth_soak_test.cpp index f0f9f5ed9..7b6294169 100644 --- a/src/impl/bch/test/abla_growth_soak_test.cpp +++ b/src/impl/bch/test/abla_growth_soak_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::abla AblaTracker budget-GROWTH soak test (M5 dynamic-sizing proof). // @@ -109,4 +110,4 @@ int main() { } std::cerr << "abla_growth_soak_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/asert_kat_test.cpp b/src/impl/bch/test/asert_kat_test.cpp index 99074ba82..abcfaf85c 100644 --- a/src/impl/bch/test/asert_kat_test.cpp +++ b/src/impl/bch/test/asert_kat_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin ASERT DAA known-answer test (M5 -- embedded body conformance). // @@ -148,4 +149,4 @@ int main() { } std::cerr << "asert_kat_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/bchn_anchor_record_test.cpp b/src/impl/bch/test/bchn_anchor_record_test.cpp index 30cbec255..0d3d931f0 100644 --- a/src/impl/bch/test/bchn_anchor_record_test.cpp +++ b/src/impl/bch/test/bchn_anchor_record_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::BchnAnchorRecord cold-start anchor test (M5, embedded-daemon body). // @@ -118,4 +119,4 @@ int main() { } std::cerr << "bchn_anchor_record_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/block_connector_test.cpp b/src/impl/bch/test/block_connector_test.cpp index 98c1ec04d..06971635e 100644 --- a/src/impl/bch/test/block_connector_test.cpp +++ b/src/impl/bch/test/block_connector_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin BlockConnector test (M5 full-block body, slice 1: block-connect). // @@ -168,4 +169,4 @@ int main() { } std::cerr << "block_connector_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/block_download_test.cpp b/src/impl/bch/test/block_download_test.cpp index c20cf5176..8cd37aa8a 100644 --- a/src/impl/bch/test/block_download_test.cpp +++ b/src/impl/bch/test/block_download_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::block_download::BlockDownloadWindow -- M5 full-block body. // Pins the windowed headers-first block-download policy that NodeP2P drives @@ -285,4 +286,4 @@ int main() std::cout << "bch block_download window: ALL PASS\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/block_ordering_test.cpp b/src/impl/bch/test/block_ordering_test.cpp index d45e5ccb6..31066e1ba 100644 --- a/src/impl/bch/test/block_ordering_test.cpp +++ b/src/impl/bch/test/block_ordering_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin BlockConnector — BIP130 ORDERING edge cases (M5 full-block body, // slice 2). The slice-1 test (block_connector_test.cpp) pinned the three @@ -207,4 +208,4 @@ int main() { } std::cerr << "block_ordering_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/cashaddr_test.cpp b/src/impl/bch/test/cashaddr_test.cpp index 62cc915b7..063ad8beb 100644 --- a/src/impl/bch/test/cashaddr_test.cpp +++ b/src/impl/bch/test/cashaddr_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::cashaddr KAT + roundtrip test (M4 CashAddr port validation). // @@ -116,4 +117,4 @@ int main() { std::cout << "cashaddr KAT: ALL " << checks << " checks PASS\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/cashtokens_transparency_test.cpp b/src/impl/bch/test/cashtokens_transparency_test.cpp index 9ff2eda21..9bb8a5856 100644 --- a/src/impl/bch/test/cashtokens_transparency_test.cpp +++ b/src/impl/bch/test/cashtokens_transparency_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin CashTokens transparency KAT (CHIP-2022-02, May 2023). // @@ -158,4 +159,4 @@ int main() << (got.size() / 2) << "-byte tx; 0xef token prefix carried opaque, " << "lossless round-trip, bound into tx_id pre-image)\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/coin_node_seam_test.cpp b/src/impl/bch/test/coin_node_seam_test.cpp index cf5ec5d4f..05119c0ce 100644 --- a/src/impl/bch/test/coin_node_seam_test.cpp +++ b/src/impl/bch/test/coin_node_seam_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::CoinNode seam-contract test (M5 seam-wire validation). // @@ -96,4 +97,4 @@ int main() { } std::cerr << "coin_node_seam_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/coinbase_author_kat_test.cpp b/src/impl/bch/test/coinbase_author_kat_test.cpp index 485376946..66a2a1abe 100644 --- a/src/impl/bch/test/coinbase_author_kat_test.cpp +++ b/src/impl/bch/test/coinbase_author_kat_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch G2 coinbase-AUTHOR KAT -- v36 output-assembly byte-parity vs oracle // @@ -222,4 +223,4 @@ int main() { std::cout << "[KAT] bch G2 coinbase-author KAT -- ALL CASES PASS\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/coinbase_kat_bytevector_test.cpp b/src/impl/bch/test/coinbase_kat_bytevector_test.cpp index f950e10ab..f496eb3a7 100644 --- a/src/impl/bch/test/coinbase_kat_bytevector_test.cpp +++ b/src/impl/bch/test/coinbase_kat_bytevector_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch coinbase KAT -- full-coinbase byte-vector vs oracle ground-truth // (DGB<->BCH pairing, slice 2; the byte-vector half promised by slice 1s @@ -124,4 +125,4 @@ int main() << (got.size() / 2) << " bytes match p2poolBCH util/pack ground-truth; " << "legacy no-SegWit serialization)\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/coinbase_kat_segwit_predicate_test.cpp b/src/impl/bch/test/coinbase_kat_segwit_predicate_test.cpp index 3c0542c52..4a63ca2d8 100644 --- a/src/impl/bch/test/coinbase_kat_segwit_predicate_test.cpp +++ b/src/impl/bch/test/coinbase_kat_segwit_predicate_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch coinbase KAT -- gated-segwit predicate pin (DGB<->BCH pairing, slice 1). // @@ -61,4 +62,4 @@ int main() << "(is_segwit_activated == false for all versions; " << "no witness-commitment vout on any BCH coinbase)\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/compact_block_connector_test.cpp b/src/impl/bch/test/compact_block_connector_test.cpp index 273af373f..7f6a44279 100644 --- a/src/impl/bch/test/compact_block_connector_test.cpp +++ b/src/impl/bch/test/compact_block_connector_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin BlockConnector compact-block test (M5 full-block body, slice (b): // BIP152 compact-block depth on the connector seam). @@ -192,4 +193,4 @@ int main() { } std::cerr << "compact_block_connector_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/embedded_block_broadcast_test.cpp b/src/impl/bch/test/embedded_block_broadcast_test.cpp index 4789c083f..3cf38cfe7 100644 --- a/src/impl/bch/test/embedded_block_broadcast_test.cpp +++ b/src/impl/bch/test/embedded_block_broadcast_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::EmbeddedDaemon::broadcast_won_block dual-path contract test // (M5 -- embedded body; broadcaster-gate A+B). @@ -162,4 +163,4 @@ int main() { } std::cerr << "embedded_block_broadcast_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/embedded_daemon_assembly_test.cpp b/src/impl/bch/test/embedded_daemon_assembly_test.cpp index ef0d29100..4ac546192 100644 --- a/src/impl/bch/test/embedded_daemon_assembly_test.cpp +++ b/src/impl/bch/test/embedded_daemon_assembly_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::EmbeddedDaemon assembly test (M5 -- embedded body). // @@ -141,4 +142,4 @@ int main() { } std::cerr << "embedded_daemon_assembly_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/embedded_getwork_test.cpp b/src/impl/bch/test/embedded_getwork_test.cpp index ea5167c84..bb07218c2 100644 --- a/src/impl/bch/test/embedded_getwork_test.cpp +++ b/src/impl/bch/test/embedded_getwork_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::EmbeddedCoinNode::getwork() contract test (M5 -- embedded body). // @@ -172,4 +173,4 @@ int main() { } std::cerr << "embedded_getwork_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/embedded_seam_workview_test.cpp b/src/impl/bch/test/embedded_seam_workview_test.cpp index 69007decd..03358590c 100644 --- a/src/impl/bch/test/embedded_seam_workview_test.cpp +++ b/src/impl/bch/test/embedded_seam_workview_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::EmbeddedDaemon production-seam WorkView test (M5 -- embedded body). // @@ -114,4 +115,4 @@ int main() { } std::cerr << "embedded_seam_workview_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/g0_canonical_pin_test.cpp b/src/impl/bch/test/g0_canonical_pin_test.cpp index f12ac5046..20c4ba581 100644 --- a/src/impl/bch/test/g0_canonical_pin_test.cpp +++ b/src/impl/bch/test/g0_canonical_pin_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch G0 canonical-pin KAT (greenlight gate G0). // @@ -168,4 +169,4 @@ int main() { } std::cerr << "bch G0 canonical-pin KAT: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/g1_oracle_byte_parity_test.cpp b/src/impl/bch/test/g1_oracle_byte_parity_test.cpp index 3ca3a7d66..3512a5be2 100644 --- a/src/impl/bch/test/g1_oracle_byte_parity_test.cpp +++ b/src/impl/bch/test/g1_oracle_byte_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::PoolConfig G1 oracle byte-parity KAT (greenlight gate G1). // @@ -129,4 +130,4 @@ int main() { } std::cerr << "g1_oracle_byte_parity_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/g1_share_serialization_parity_test.cpp b/src/impl/bch/test/g1_share_serialization_parity_test.cpp index 4b7d5aeed..da82a4b08 100644 --- a/src/impl/bch/test/g1_share_serialization_parity_test.cpp +++ b/src/impl/bch/test/g1_share_serialization_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch G1 share-serialization byte-parity KAT (greenlight gate G1, share layer). // @@ -156,4 +157,4 @@ int main() std::cout << "bch G1 share-serialization byte-parity KAT: PASS " "(share_type + hash_link v35/v36 + crossing-floor v35 pinned)\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/g2_ratchet_gate_kat_test.cpp b/src/impl/bch/test/g2_ratchet_gate_kat_test.cpp index 62a867481..ca404915c 100644 --- a/src/impl/bch/test/g2_ratchet_gate_kat_test.cpp +++ b/src/impl/bch/test/g2_ratchet_gate_kat_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch G2 ratchet gate-logic KAT (greenlight gate G2, staged-migration anchor). // @@ -141,4 +142,4 @@ int main() << "bch G2 ratchet gate-logic KAT, " << failures << " failure(s)\n"; assert(failures == 0); return failures ? 1 : 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/genesis_conformance_test.cpp b/src/impl/bch/test/genesis_conformance_test.cpp index 12a691632..8ed7018c9 100644 --- a/src/impl/bch/test/genesis_conformance_test.cpp +++ b/src/impl/bch/test/genesis_conformance_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::BCHChainParams -- genesis-hash conformance vs Bitcoin Cash Node. // @@ -64,4 +65,4 @@ int main() std::cout << "bch genesis conformance vs BCHN v29.0.0: ALL PASS\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/header_sync_progress_test.cpp b/src/impl/bch/test/header_sync_progress_test.cpp index 965d33b08..b9753d7b5 100644 --- a/src/impl/bch/test/header_sync_progress_test.cpp +++ b/src/impl/bch/test/header_sync_progress_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::header_sync SYNC-TO-PEER-TIP sequence soak (M5 full-block body). // @@ -287,4 +288,4 @@ int main() else std::cout << "bch header_sync sync-to-peer-tip soak: " << failures << " FAIL\n"; return failures == 0 ? 0 : 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/header_sync_test.cpp b/src/impl/bch/test/header_sync_test.cpp index dfbd444d3..f96323a3c 100644 --- a/src/impl/bch/test/header_sync_test.cpp +++ b/src/impl/bch/test/header_sync_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin::header_sync::classify_headers_batch -- M5 full-block body. // Pins the headers-first IBD continuation policy that NodeP2P's `headers` @@ -92,4 +93,4 @@ int main() std::cout << "bch header_sync classify + continue-locator: ALL PASS\n"; return 0; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/reorg_connect_test.cpp b/src/impl/bch/test/reorg_connect_test.cpp index 627f3cf2f..89d4003b4 100644 --- a/src/impl/bch/test/reorg_connect_test.cpp +++ b/src/impl/bch/test/reorg_connect_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin BlockConnector -- REORG / DISCONNECT leg (M5 full-block body). // @@ -170,4 +171,4 @@ int main() { } std::cerr << "reorg_connect_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/reorg_rerequest_test.cpp b/src/impl/bch/test/reorg_rerequest_test.cpp index 5a89f3602..58174b463 100644 --- a/src/impl/bch/test/reorg_rerequest_test.cpp +++ b/src/impl/bch/test/reorg_rerequest_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin reorg re-request test (M5 full-block body). // @@ -166,4 +167,4 @@ int main() { } std::cerr << "reorg_rerequest_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bch/test/utxo_connect_test.cpp b/src/impl/bch/test/utxo_connect_test.cpp index 4836846ed..c4e529723 100644 --- a/src/impl/bch/test/utxo_connect_test.cpp +++ b/src/impl/bch/test/utxo_connect_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // bch::coin UTXO-connect / Phase-4 revalidate test (M5 full-block body, (a)). // @@ -161,4 +162,4 @@ int main() { } std::cerr << "utxo_connect_test: " << failures << " FAILURE(S)\n"; return 1; -} +} \ No newline at end of file diff --git a/src/impl/bitcoin_family/coin/base_block.hpp b/src/impl/bitcoin_family/coin/base_block.hpp index 5517cccfb..c7e89218f 100644 --- a/src/impl/bitcoin_family/coin/base_block.hpp +++ b/src/impl/bitcoin_family/coin/base_block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Generic Bitcoin-family block header types. @@ -87,4 +88,4 @@ struct BlockHeaderType : SmallBlockHeaderType }; } // namespace coin -} // namespace bitcoin_family +} // namespace bitcoin_family \ No newline at end of file diff --git a/src/impl/bitcoin_family/coin/base_p2p_messages.hpp b/src/impl/bitcoin_family/coin/base_p2p_messages.hpp index c28f660df..f7b9d9605 100644 --- a/src/impl/bitcoin_family/coin/base_p2p_messages.hpp +++ b/src/impl/bitcoin_family/coin/base_p2p_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Generic Bitcoin wire protocol message types. @@ -334,4 +335,4 @@ END_MESSAGE() } // namespace p2p } // namespace coin -} // namespace bitcoin_family +} // namespace bitcoin_family \ No newline at end of file diff --git a/src/impl/bitcoin_family/coin/base_transaction.hpp b/src/impl/bitcoin_family/coin/base_transaction.hpp index 8664cdb75..a70df30b1 100644 --- a/src/impl/bitcoin_family/coin/base_transaction.hpp +++ b/src/impl/bitcoin_family/coin/base_transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Generic Bitcoin-family transaction primitive types. @@ -54,4 +55,4 @@ class TxOut }; } // namespace coin -} // namespace bitcoin_family +} // namespace bitcoin_family \ No newline at end of file diff --git a/src/impl/bitcoin_family/coin/chain_params.hpp b/src/impl/bitcoin_family/coin/chain_params.hpp index be808214b..cc9166a00 100644 --- a/src/impl/bitcoin_family/coin/chain_params.hpp +++ b/src/impl/bitcoin_family/coin/chain_params.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Generic Bitcoin-family chain parameters for header validation. @@ -87,4 +88,4 @@ inline uint32_t calculate_next_work_required( } } // namespace coin -} // namespace bitcoin_family +} // namespace bitcoin_family \ No newline at end of file diff --git a/src/impl/bitcoin_family/coin/softfork_check.hpp b/src/impl/bitcoin_family/coin/softfork_check.hpp index f46077a0b..492a15a73 100644 --- a/src/impl/bitcoin_family/coin/softfork_check.hpp +++ b/src/impl/bitcoin_family/coin/softfork_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -36,4 +37,4 @@ inline void collect_softfork_names(const nlohmann::json& value, } } -} // namespace bitcoin_family::coin +} // namespace bitcoin_family::coin \ No newline at end of file diff --git a/src/impl/bitcoin_family/coin/txidcache.hpp b/src/impl/bitcoin_family/coin/txidcache.hpp index 2b6f146c7..dcadd5262 100644 --- a/src/impl/bitcoin_family/coin/txidcache.hpp +++ b/src/impl/bitcoin_family/coin/txidcache.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -83,4 +84,4 @@ class TXIDCache } // namespace coin -} // namespace bitcoin_family +} // namespace bitcoin_family \ No newline at end of file diff --git a/src/impl/btc/auto_ratchet.hpp b/src/impl/btc/auto_ratchet.hpp index b1bd718eb..fd2e7f9ae 100644 --- a/src/impl/btc/auto_ratchet.hpp +++ b/src/impl/btc/auto_ratchet.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // AutoRatchet: autonomous share version transition state machine. @@ -352,4 +353,4 @@ class AutoRatchet } }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/block.hpp b/src/impl/btc/coin/block.hpp index 1061ae8fe..9d8001fa2 100644 --- a/src/impl/btc/coin/block.hpp +++ b/src/impl/btc/coin/block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "transaction.hpp" diff --git a/src/impl/btc/coin/block_broadcast.hpp b/src/impl/btc/coin/block_broadcast.hpp index aa1b28185..39ffe2fd7 100644 --- a/src/impl/btc/coin/block_broadcast.hpp +++ b/src/impl/btc/coin/block_broadcast.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // FALLBACK broadcast orchestration for a WON block. @@ -57,4 +58,4 @@ inline bool broadcast_block_for_connect( } } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/block_json.hpp b/src/impl/btc/coin/block_json.hpp index fb8f78755..4b473a31e 100644 --- a/src/impl/btc/coin/block_json.hpp +++ b/src/impl/btc/coin/block_json.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// block_to_explorer_json(): Convert a BlockType into litecoind-compatible @@ -256,4 +257,4 @@ inline nlohmann::json block_to_explorer_json( } } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/chain_seeds.hpp b/src/impl/btc/coin/chain_seeds.hpp index ec5687c32..37a0d9dc0 100644 --- a/src/impl/btc/coin/chain_seeds.hpp +++ b/src/impl/btc/coin/chain_seeds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DNS seed hostnames and hardcoded fallback IPs for Bitcoin P2P networks. @@ -103,4 +104,4 @@ inline std::vector btc_fixed_seeds(bool testnet) } } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/coin_node.cpp b/src/impl/btc/coin/coin_node.cpp index 58e2fc789..15724359b 100644 --- a/src/impl/btc/coin/coin_node.cpp +++ b/src/impl/btc/coin/coin_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "coin_node.hpp" #include @@ -47,4 +48,4 @@ bool CoinNode::submit_block_hex(const std::string& block_hex, bool ignore_failur } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/coin_node.hpp b/src/impl/btc/coin/coin_node.hpp index 61441945b..964e7d9a1 100644 --- a/src/impl/btc/coin/coin_node.hpp +++ b/src/impl/btc/coin/coin_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -58,4 +59,4 @@ class CoinNode : public core::coin::ICoinNode } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/compact_blocks.hpp b/src/impl/btc/coin/compact_blocks.hpp index 43e789d45..91f6db303 100644 --- a/src/impl/btc/coin/compact_blocks.hpp +++ b/src/impl/btc/coin/compact_blocks.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BIP 152 Compact Block Support @@ -316,4 +317,4 @@ inline CompactBlockReconstructionResult ReconstructBlock( } } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/header_chain.hpp b/src/impl/btc/coin/header_chain.hpp index 07e7dc411..3aa4a0c47 100644 --- a/src/impl/btc/coin/header_chain.hpp +++ b/src/impl/btc/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BTC Header Chain @@ -1239,4 +1240,4 @@ class HeaderChain { }; } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/mempool.hpp b/src/impl/btc/coin/mempool.hpp index 781c6ad80..a0614bd9b 100644 --- a/src/impl/btc/coin/mempool.hpp +++ b/src/impl/btc/coin/mempool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// LTC Mempool — Phase 2 + UTXO fee computation @@ -743,4 +744,4 @@ class Mempool { }; } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/node.hpp b/src/impl/btc/coin/node.hpp index 739495ae0..e7b78abdd 100644 --- a/src/impl/btc/coin/node.hpp +++ b/src/impl/btc/coin/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -183,4 +184,4 @@ class Node : public btc::interfaces::Node } // namespace coin -} // namespace coin +} // namespace coin \ No newline at end of file diff --git a/src/impl/btc/coin/node_interface.hpp b/src/impl/btc/coin/node_interface.hpp index b2e983149..d90635a43 100644 --- a/src/impl/btc/coin/node_interface.hpp +++ b/src/impl/btc/coin/node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -33,6 +34,4 @@ struct Node } // namespace interfaces -} // namespace btc::coin - - +} // namespace btc::coin \ No newline at end of file diff --git a/src/impl/btc/coin/p2p_connection.cpp b/src/impl/btc/coin/p2p_connection.cpp index 1e175fea7..835a2bc73 100644 --- a/src/impl/btc/coin/p2p_connection.cpp +++ b/src/impl/btc/coin/p2p_connection.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_connection.hpp" namespace btc @@ -37,4 +38,4 @@ void Connection::get_header(uint256 id, BlockHeaderType response) } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/p2p_connection.hpp b/src/impl/btc/coin/p2p_connection.hpp index 49b8b6d24..c596a6345 100644 --- a/src/impl/btc/coin/p2p_connection.hpp +++ b/src/impl/btc/coin/p2p_connection.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "block.hpp" @@ -87,4 +88,4 @@ class Connection } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/p2p_messages.hpp b/src/impl/btc/coin/p2p_messages.hpp index 238c0eae4..933f70a3c 100644 --- a/src/impl/btc/coin/p2p_messages.hpp +++ b/src/impl/btc/coin/p2p_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "transaction.hpp" diff --git a/src/impl/btc/coin/p2p_node.cpp b/src/impl/btc/coin/p2p_node.cpp index ef654cc41..f9c6eaf56 100644 --- a/src/impl/btc/coin/p2p_node.cpp +++ b/src/impl/btc/coin/p2p_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_node.hpp" namespace btc diff --git a/src/impl/btc/coin/p2p_node.hpp b/src/impl/btc/coin/p2p_node.hpp index 5d6d20506..33da3d4e7 100644 --- a/src/impl/btc/coin/p2p_node.hpp +++ b/src/impl/btc/coin/p2p_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "p2p_messages.hpp" @@ -1041,4 +1042,4 @@ class NodeP2P : public core::ICommunicator, public core::INetwork, public core:: } // namespace node -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/rpc.cpp b/src/impl/btc/coin/rpc.cpp index d945e41e3..eb35f7700 100644 --- a/src/impl/btc/coin/rpc.cpp +++ b/src/impl/btc/coin/rpc.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "rpc.hpp" #include diff --git a/src/impl/btc/coin/rpc.hpp b/src/impl/btc/coin/rpc.hpp index 1b7fcf408..a30abf3af 100644 --- a/src/impl/btc/coin/rpc.hpp +++ b/src/impl/btc/coin/rpc.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "block.hpp" @@ -86,6 +87,4 @@ struct RPCAuthData } // namespace coin -} // namespace btc - - +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/rpc_data.hpp b/src/impl/btc/coin/rpc_data.hpp index 8a8f6aa94..f379f0793 100644 --- a/src/impl/btc/coin/rpc_data.hpp +++ b/src/impl/btc/coin/rpc_data.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/impl/btc/coin/softfork_check.hpp b/src/impl/btc/coin/softfork_check.hpp index cecc0451b..2349e6a24 100644 --- a/src/impl/btc/coin/softfork_check.hpp +++ b/src/impl/btc/coin/softfork_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -36,4 +37,4 @@ inline void collect_softfork_names(const nlohmann::json& value, } } -} // namespace btc::coin +} // namespace btc::coin \ No newline at end of file diff --git a/src/impl/btc/coin/template_builder.hpp b/src/impl/btc/coin/template_builder.hpp index bf5ee6d1b..e0cc7d76c 100644 --- a/src/impl/btc/coin/template_builder.hpp +++ b/src/impl/btc/coin/template_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase 3: LTC Template Builder @@ -413,4 +414,4 @@ class EmbeddedCoinNode : public CoinNodeInterface { }; } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/transaction.cpp b/src/impl/btc/coin/transaction.cpp index 0cb0cdd76..885205411 100644 --- a/src/impl/btc/coin/transaction.cpp +++ b/src/impl/btc/coin/transaction.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "transaction.hpp" namespace btc diff --git a/src/impl/btc/coin/transaction.hpp b/src/impl/btc/coin/transaction.hpp index 5af5f7918..a7f384ae3 100644 --- a/src/impl/btc/coin/transaction.hpp +++ b/src/impl/btc/coin/transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -217,4 +218,4 @@ void SerializeTransaction(const TxType& tx, StreamType& s, const TxParams& param } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/coin/txidcache.hpp b/src/impl/btc/coin/txidcache.hpp index 58110032a..078980b12 100644 --- a/src/impl/btc/coin/txidcache.hpp +++ b/src/impl/btc/coin/txidcache.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -83,4 +84,4 @@ class TXIDCache } // namespace coin -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/config.hpp b/src/impl/btc/config.hpp index 2a53ec9b5..bd775728d 100644 --- a/src/impl/btc/config.hpp +++ b/src/impl/btc/config.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "config_pool.hpp" @@ -8,4 +9,4 @@ namespace btc using Config = core::Config; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/config_coin.cpp b/src/impl/btc/config_coin.cpp index f506bb233..a81d5227a 100644 --- a/src/impl/btc/config_coin.cpp +++ b/src/impl/btc/config_coin.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_coin.hpp" #include @@ -32,4 +33,4 @@ void CoinConfig::load() PARSE_CONFIG(node, testnet, bool); } -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/config_coin.hpp b/src/impl/btc/config_coin.hpp index 06089e94d..b77eeb856 100644 --- a/src/impl/btc/config_coin.hpp +++ b/src/impl/btc/config_coin.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -119,4 +120,4 @@ class CoinConfig : protected core::Fileconfig // uint256 dumb_scrypt_diff; }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/config_pool.cpp b/src/impl/btc/config_pool.cpp index 60531f23a..91d820f77 100644 --- a/src/impl/btc/config_pool.cpp +++ b/src/impl/btc/config_pool.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_pool.hpp" #include @@ -45,4 +46,4 @@ void PoolConfig::load() } } -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/config_pool.hpp b/src/impl/btc/config_pool.hpp index 968ef0600..e1e3dd382 100644 --- a/src/impl/btc/config_pool.hpp +++ b/src/impl/btc/config_pool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -228,4 +229,4 @@ class PoolConfig : protected core::Fileconfig std::vector m_bootstrap_addrs; }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/donation_consensus.hpp b/src/impl/btc/donation_consensus.hpp index 210449b59..3eb6c6dcf 100644 --- a/src/impl/btc/donation_consensus.hpp +++ b/src/impl/btc/donation_consensus.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // donation_consensus.hpp — Consensus-level donation script validation for LTC p2pool shares. @@ -120,4 +121,4 @@ build_expected_payouts(ShareTracker& tracker, return tracker.get_expected_payouts(best_share_hash, block_target, subsidy, donation_script); } -} // namespace btc::consensus +} // namespace btc::consensus \ No newline at end of file diff --git a/src/impl/btc/messages.hpp b/src/impl/btc/messages.hpp index 8b782b012..c32dc574e 100644 --- a/src/impl/btc/messages.hpp +++ b/src/impl/btc/messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/block.hpp" @@ -188,4 +189,4 @@ using Handler = MessageHandler< message_remember_tx >; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/node.cpp b/src/impl/btc/node.cpp index 3dbb66f9b..dba41b03a 100644 --- a/src/impl/btc/node.cpp +++ b/src/impl/btc/node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include @@ -2416,4 +2417,4 @@ void NodeImpl::set_rss_limit_mb(long mb) g_rss_limit_mb = mb; } -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/node.hpp b/src/impl/btc/node.hpp index c953d9949..c8a80dc20 100644 --- a/src/impl/btc/node.hpp +++ b/src/impl/btc/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "config.hpp" @@ -649,4 +650,4 @@ class Actual : public pool::Protocol using Node = pool::NodeBridge; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/peer.hpp b/src/impl/btc/peer.hpp index 6719c81f7..9d7bd88d3 100644 --- a/src/impl/btc/peer.hpp +++ b/src/impl/btc/peer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/transaction.hpp" diff --git a/src/impl/btc/pool_monitor.hpp b/src/impl/btc/pool_monitor.hpp index 3d7be3db1..b5c420e62 100644 --- a/src/impl/btc/pool_monitor.hpp +++ b/src/impl/btc/pool_monitor.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 3L: Log-based pool monitoring for attack detection. @@ -357,4 +358,4 @@ class PoolMonitor } }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/protocol_actual.cpp b/src/impl/btc/protocol_actual.cpp index 9e6917620..72bb7e384 100644 --- a/src/impl/btc/protocol_actual.cpp +++ b/src/impl/btc/protocol_actual.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" @@ -271,4 +272,4 @@ void Actual::HANDLER(forget_tx) } } -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/protocol_legacy.cpp b/src/impl/btc/protocol_legacy.cpp index 3f515efa4..4378c82de 100644 --- a/src/impl/btc/protocol_legacy.cpp +++ b/src/impl/btc/protocol_legacy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" diff --git a/src/impl/btc/redistribute.hpp b/src/impl/btc/redistribute.hpp index f85ff153e..3de792865 100644 --- a/src/impl/btc/redistribute.hpp +++ b/src/impl/btc/redistribute.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Redistribute V2: advanced redistribution policy for shares from miners @@ -496,4 +497,4 @@ class Redistributor } }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/share.hpp b/src/impl/btc/share.hpp index c536dcde0..8cdbf7b54 100644 --- a/src/impl/btc/share.hpp +++ b/src/impl/btc/share.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/block.hpp" @@ -313,5 +314,4 @@ struct ShareChain : chain::ShareChain }; -} // namespace btc - +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/share_check.hpp b/src/impl/btc/share_check.hpp index 262b32dba..bd9b4ddd3 100644 --- a/src/impl/btc/share_check.hpp +++ b/src/impl/btc/share_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // P2: Share verification — check_hash_link, check_merkle_link, share init/check @@ -3355,4 +3356,4 @@ uint256 create_local_share( return share_hash; } -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/share_messages.hpp b/src/impl/btc/share_messages.hpp index c1b154a0e..10ec2a202 100644 --- a/src/impl/btc/share_messages.hpp +++ b/src/impl/btc/share_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // share_messages.hpp — V36 share-embedded messaging: decryption + validation // // Port of p2pool/share_messages.py (consensus-critical portions). @@ -576,4 +577,4 @@ inline std::vector create_message_data( return encrypt_message_envelope(inner, authority_pubkey); } -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/share_tracker.hpp b/src/impl/btc/share_tracker.hpp index f2e1bd213..acd730da1 100644 --- a/src/impl/btc/share_tracker.hpp +++ b/src/impl/btc/share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Portable 128-bit multiply-shift: (a * b) >> shift @@ -2870,4 +2871,4 @@ class ShareTracker CumulativeWeights m_decayed_cache_result; }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/share_types.hpp b/src/impl/btc/share_types.hpp index 0c32b7489..bac6d48fa 100644 --- a/src/impl/btc/share_types.hpp +++ b/src/impl/btc/share_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -193,4 +194,4 @@ struct AbsworkV36Format } }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/btc/stratum/tx_data_memo.hpp b/src/impl/btc/stratum/tx_data_memo.hpp index 5d46eced4..8789cb849 100644 --- a/src/impl/btc/stratum/tx_data_memo.hpp +++ b/src/impl/btc/stratum/tx_data_memo.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // H5 leak-fix seam (acceptance-gate testable unit). // @@ -66,4 +67,4 @@ inline std::shared_ptr> tx_data_memo_get_or_build( return txd; } -} // namespace btc::stratum::detail +} // namespace btc::stratum::detail \ No newline at end of file diff --git a/src/impl/btc/stratum/work_source.cpp b/src/impl/btc/stratum/work_source.cpp index 2fb97ae46..561a116d3 100644 --- a/src/impl/btc/stratum/work_source.cpp +++ b/src/impl/btc/stratum/work_source.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // btc::stratum::BTCWorkSource — Stage 4a skeleton. // // All IWorkSource methods are stubbed to safe defaults. Subsequent @@ -1093,4 +1094,4 @@ void BTCWorkSource::set_donation_script(std::vector script) donation_script_ = std::move(script); } -} // namespace btc::stratum +} // namespace btc::stratum \ No newline at end of file diff --git a/src/impl/btc/stratum/work_source.hpp b/src/impl/btc/stratum/work_source.hpp index 9c302ea4d..a467a0596 100644 --- a/src/impl/btc/stratum/work_source.hpp +++ b/src/impl/btc/stratum/work_source.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // btc::stratum::BTCWorkSource — concrete `core::stratum::IWorkSource` @@ -289,4 +290,4 @@ class BTCWorkSource : public core::stratum::IWorkSource std::shared_ptr cached_template() const; }; -} // namespace btc::stratum +} // namespace btc::stratum \ No newline at end of file diff --git a/src/impl/btc/test/auto_ratchet_sim_test.cpp b/src/impl/btc/test/auto_ratchet_sim_test.cpp index 198d66f2d..bedd2415d 100644 --- a/src/impl/btc/test/auto_ratchet_sim_test.cpp +++ b/src/impl/btc/test/auto_ratchet_sim_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // btc_auto_ratchet_sim_test: FENCED, additive rig-free SIM KAT that arms the // BTC G2 staged-migration harness (scripts/btc_g2_ratchet_staged_migration_harness.sh) // C2/C3/C4 rows WITHOUT a SHA256d rig — the mirror of DGB #427's --sim-votes. @@ -233,4 +234,4 @@ TEST(BTC_AutoRatchetSim, SSOT2_OracleFloorVsInlineCeilBoundary) // Forms are now identical at every point (boundary and beyond). EXPECT_TRUE (oracle_floor_ok(uint288(61), total)); EXPECT_TRUE (inline_tail_ok (uint288(61), total)); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/block_broadcast_connect_test.cpp b/src/impl/btc/test/block_broadcast_connect_test.cpp index 055c6d74f..b269a0fdd 100644 --- a/src/impl/btc/test/block_broadcast_connect_test.cpp +++ b/src/impl/btc/test/block_broadcast_connect_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // btc::coin::broadcast_block_for_connect CONNECT-AUTHORITATIVE KATs. // @@ -79,4 +80,4 @@ TEST(BtcBlockBroadcastConnect, NullP2pRpcConnects) { EXPECT_TRUE(btc::coin::broadcast_block_for_connect(no_p2p, submit)); EXPECT_EQ(rpc_calls, 1); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/block_broadcast_guard_test.cpp b/src/impl/btc/test/block_broadcast_guard_test.cpp index 8d96856f0..d4f447f60 100644 --- a/src/impl/btc/test/block_broadcast_guard_test.cpp +++ b/src/impl/btc/test/block_broadcast_guard_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // btc::coin::broadcast_block_with_fallback dual-path guard KATs. // @@ -88,4 +89,4 @@ TEST(BtcBlockBroadcastGuard, NoSinkIsSafeFalse) { bool ok = true; EXPECT_NO_THROW(ok = btc::coin::broadcast_block_with_fallback({}, {})); EXPECT_FALSE(ok); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/block_broadcast_test.cpp b/src/impl/btc/test/block_broadcast_test.cpp index 1b615f3c8..4d4ee85b2 100644 --- a/src/impl/btc/test/block_broadcast_test.cpp +++ b/src/impl/btc/test/block_broadcast_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Broadcaster-gate verify test (path 3): proves the WON-BLOCK broadcast obeys // FALLBACK semantics and NEVER silent-drops. Standalone harness in the style // of tx_data_memo_test.cpp -- no btc/test CMake plumbing required. @@ -99,4 +100,4 @@ int main() { std::printf(g_fails ? "\nFAILED (%d)\n" : "\nALL PASS\n", g_fails); return g_fails ? 1 : 0; -} +} \ No newline at end of file diff --git a/src/impl/btc/test/f10b_version_punish_removal_test.cpp b/src/impl/btc/test/f10b_version_punish_removal_test.cpp index 62f87dd0d..d16752504 100644 --- a/src/impl/btc/test/f10b_version_punish_removal_test.cpp +++ b/src/impl/btc/test/f10b_version_punish_removal_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // F10/(b) version-punish-removal KAT — guards the #288 tip-selection axis. // // This branch deletes should_punish_version() (the non-canonical 95%-flat-count @@ -108,4 +109,4 @@ TEST(BTC_F10b_VersionPunishRemoval, AcceptGateRejectsBelowSixtyWeighted) { TEST(BTC_F10b_VersionPunishRemoval, NaughtyIsTheSoleSurvivingPunish) { EXPECT_EQ(0, head_reason_after_deletion(0)); EXPECT_EQ(3, head_reason_after_deletion(3)); // naughty propagation preserved -} +} \ No newline at end of file diff --git a/src/impl/btc/test/f11_donation_invariance_test.cpp b/src/impl/btc/test/f11_donation_invariance_test.cpp index 7dfc5efed..82e9aa3ba 100644 --- a/src/impl/btc/test/f11_donation_invariance_test.cpp +++ b/src/impl/btc/test/f11_donation_invariance_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // F11 value-invariance KAT — guards the canonical exclude-then-append donation // handling in the BTC v36 payout sort (src/impl/btc/share_check.hpp, // build_payout_outputs_excluding_donation). @@ -178,4 +179,4 @@ TEST(BTC_F11_DonationInvariance, RealDonationConstantsPinned) { EXPECT_EQ(p.back(), 0xac); EXPECT_NE(c, p); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/g01_share_format_parity_test.cpp b/src/impl/btc/test/g01_share_format_parity_test.cpp index 3ac203b10..1e3b721cf 100644 --- a/src/impl/btc/test/g01_share_format_parity_test.cpp +++ b/src/impl/btc/test/g01_share_format_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -90,4 +91,4 @@ TEST(BTC_g01_share_format, ShareVersionAdditiveIsExactlyV36) // Boundary is exact: 36 activates, 35 (max baseline) does not. EXPECT_TRUE (core::version_gate::is_v36_active(36)); EXPECT_FALSE(core::version_gate::is_v36_active(35)); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/g3_block_production_test.cpp b/src/impl/btc/test/g3_block_production_test.cpp index e0289e913..f4a136cf7 100644 --- a/src/impl/btc/test/g3_block_production_test.cpp +++ b/src/impl/btc/test/g3_block_production_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // G3 block-production harness (pin-independent scaffolding). // // Proves the WON-BLOCK production path FOUND -> ASSEMBLED -> ACCEPTED behaves @@ -168,4 +169,4 @@ int main() { std::printf(g_fails ? "\nFAILED (%d)\n" : "\nALL PASS\n", g_fails); return g_fails ? 1 : 0; -} +} \ No newline at end of file diff --git a/src/impl/btc/test/regtest_sharechain_isolation_test.cpp b/src/impl/btc/test/regtest_sharechain_isolation_test.cpp index c57c5f5e9..e810253f1 100644 --- a/src/impl/btc/test/regtest_sharechain_isolation_test.cpp +++ b/src/impl/btc/test/regtest_sharechain_isolation_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // btc::sharechain_net_name isolation KATs. // @@ -52,4 +53,4 @@ TEST(RegtestSharechainIsolation, AllThreeNamespacesDistinct) EXPECT_NE(rt, tn); EXPECT_NE(rt, mn); EXPECT_NE(tn, mn); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/share_test.cpp b/src/impl/btc/test/share_test.cpp index 6d4f499cb..341ad2968 100644 --- a/src/impl/btc/test/share_test.cpp +++ b/src/impl/btc/test/share_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // PackStream stream_share; // stream_share.from_hex("21fd0702fe02000020617dfa46bf73eb96548e0b039a647d35b387ed0cb1a6e51c80092175857d3f5b3ac4ff62f1a9001bc0254dda4d00fe065ba137d8e108ef134db29b7e33f46327f13626975c0c2a190082018f3d04d03aee002cfabe6d6d21102609e852babee96639fbb3b65588bbcc419720fec56da52e47120c4804a501000000000000000a5f5f6332706f6f6c5f5ffc88aa669a2cd3c1310067ae7e47a7869b330d30b691c61b46fb483b0a0000000000002102f24e44938c7bde43245d2a17c7fe424fbebc63f05317dfdace08a95a2f10d5efe4248d9eb63c2de431a93f0c94e857920cb3f70163dba595de7720e6cc014203517d2164368b766e6b9d0598510a7bbfc9882940ebfe3f65bb72173c3dbf105802f24e44938c7bde43245d2a17c7fe424fbebc63f05317dfdace08a95a2f10d5ef1025a29236b072d75cde8637584a3ed2fe0bcd4aadb5824b61cc42b4414e143d020000000195cbb26f405ead27fcd8cf84155cfcfab722a0cfdb3a2c735fce15fb19bc8ae4ffff0f1e8888001e3bc4ff62cc210000df798a25160000000000000000000000000000000001000000986dae33074d8c439a5dc61c2019a86726ebd1cf0eb0240582ccc0b249d12ba7fd9c0102f24e44938c7bde43245d2a17c7fe424fbebc63f05317dfdace08a95a2f10d5efe4248d9eb63c2de431a93f0c94e857920cb3f70163dba595de7720e6cc014203"); @@ -128,4 +129,4 @@ TEST(BTC_subsidy, MainnetIntervalUnchanged) EXPECT_EQ(get_block_subsidy(209'999), 50 * COIN); EXPECT_EQ(get_block_subsidy(210'000), 25 * COIN); EXPECT_EQ(get_block_subsidy(210'000, 210'000u), 25 * COIN); -} +} \ No newline at end of file diff --git a/src/impl/btc/test/stratum_merkle_branch_test.cpp b/src/impl/btc/test/stratum_merkle_branch_test.cpp index 8f631492d..5a3108456 100644 --- a/src/impl/btc/test/stratum_merkle_branch_test.cpp +++ b/src/impl/btc/test/stratum_merkle_branch_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Producer/consumer merkle-branch contract KAT for the BTC stratum work source. // // Regression guard for the latent bad-txnmrklroot defect fixed in PR #570. @@ -103,4 +104,4 @@ TEST(StratumMerkleBranch, PreFixBuilderDivergesOnPopulated) { EXPECT_NE(fold_branches(COINBASE, buggy_siblings(txs)), body_root(COINBASE, txs)) << "N=" << n << " buggy builder unexpectedly matched — guard is blind"; } -} +} \ No newline at end of file diff --git a/src/impl/btc/test/template_cache_epoch_test.cpp b/src/impl/btc/test/template_cache_epoch_test.cpp index 626a82a44..a82fa6a01 100644 --- a/src/impl/btc/test/template_cache_epoch_test.cpp +++ b/src/impl/btc/test/template_cache_epoch_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Value-invariance gate for the BTC stratum work-template cache (heap opt). // // work_source.cpp build_connection_coinbase / get_current_work_template / @@ -91,4 +92,4 @@ int main() { std::printf("== %s (%d failure%s) ==\n", g_fails ? "FAIL" : "ALL PASS", g_fails, g_fails == 1 ? "" : "s"); return g_fails ? 1 : 0; -} +} \ No newline at end of file diff --git a/src/impl/btc/test/template_parity_test.cpp b/src/impl/btc/test/template_parity_test.cpp index e650c287c..cdf0cb723 100644 --- a/src/impl/btc/test/template_parity_test.cpp +++ b/src/impl/btc/test/template_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // B6 template parity check: c2pool-btc algorithmic functions vs Bitcoin // Core consensus oracles. This is a standalone smoke-style harness — not // a full gtest fixture — so it can be built and run without restoring the @@ -193,4 +194,4 @@ int main() else std::printf("FAILED %d parity check(s).\n", g_fails); return g_fails; -} +} \ No newline at end of file diff --git a/src/impl/btc/test/tx_data_memo_test.cpp b/src/impl/btc/test/tx_data_memo_test.cpp index 7a1889f71..6015b0051 100644 --- a/src/impl/btc/test/tx_data_memo_test.cpp +++ b/src/impl/btc/test/tx_data_memo_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // H5 acceptance gate: deterministic pointer-identity + O(1) proof for the // tx_data memo (the work_source.cpp:634 churn/leak fix). Standalone harness // in the style of template_parity_test.cpp -- no btc/test CMake plumbing @@ -106,4 +107,4 @@ int main() { std::printf("\n%s (%d failures)\n", g_fails ? "FAILED" : "ALL PASS", g_fails); return g_fails ? 1 : 0; -} +} \ No newline at end of file diff --git a/src/impl/btc/test/witness_commitment_merkle_test.cpp b/src/impl/btc/test/witness_commitment_merkle_test.cpp index faec8eafa..018e4387c 100644 --- a/src/impl/btc/test/witness_commitment_merkle_test.cpp +++ b/src/impl/btc/test/witness_commitment_merkle_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // KAT: BIP141 witness-commitment merkle-root leaf-0 contract. // // The coinbase transaction's wtxid is DEFINED as 32 zero bytes and MUST occupy @@ -63,4 +64,4 @@ TEST(BTC_witness_commitment, OrderSensitive) { uint256 a = wt(0x11), b = wt(0x22); EXPECT_NE(witness_merkle_root({a, b}).GetHex(), witness_merkle_root({b, a}).GetHex()); -} +} \ No newline at end of file diff --git a/src/impl/btc/whale_departure.hpp b/src/impl/btc/whale_departure.hpp index db41c6765..9a75bebec 100644 --- a/src/impl/btc/whale_departure.hpp +++ b/src/impl/btc/whale_departure.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 1c: Whale departure recovery — non-consensus local heuristic. @@ -190,4 +191,4 @@ class WhaleDepartureDetector uint32_t gap_trigger_periods_ = 8; // share gap trigger }; -} // namespace btc +} // namespace btc \ No newline at end of file diff --git a/src/impl/dash/auto_ratchet.hpp b/src/impl/dash/auto_ratchet.hpp index db5d9e387..747b9fb75 100644 --- a/src/impl/dash/auto_ratchet.hpp +++ b/src/impl/dash/auto_ratchet.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DASH v36-native MINT-side auto-ratchet of the P2P accept floor. @@ -134,4 +135,4 @@ inline uint32_t apply_min_protocol_ratchet_decision( window_weights, best_version, current_floor, target_floor); } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/block_relay.hpp b/src/impl/dash/block_relay.hpp index 50c195422..a8f56716a 100644 --- a/src/impl/dash/block_relay.hpp +++ b/src/impl/dash/block_relay.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — WonBlockRelay: embedded-P2P won-block relay framer (LEAF). @@ -86,4 +87,4 @@ class WonBlockRelay std::map m_pending; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/block_relay_binding.hpp b/src/impl/dash/block_relay_binding.hpp index 19296a46c..54ba534ce 100644 --- a/src/impl/dash/block_relay_binding.hpp +++ b/src/impl/dash/block_relay_binding.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — WonBlockRelay <-> DashBroadcaster binding (LEAF). @@ -79,4 +80,4 @@ class WonBlockRelayBinding WonBlockRelayPlanner& m_planner; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/block_relay_dual_arm.hpp b/src/impl/dash/block_relay_dual_arm.hpp index 4632f58f1..385e921d2 100644 --- a/src/impl/dash/block_relay_dual_arm.hpp +++ b/src/impl/dash/block_relay_dual_arm.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — WonBlock dual-arm delivery plan + reached-network verdict (LEAF). @@ -114,4 +115,4 @@ class DualArmPlanner WonBlockRelayBinding& m_binding; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/block_relay_plan.hpp b/src/impl/dash/block_relay_plan.hpp index c060596a0..5af8b9865 100644 --- a/src/impl/dash/block_relay_plan.hpp +++ b/src/impl/dash/block_relay_plan.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — WonBlockRelay live-slots reply path (LEAF). @@ -147,4 +148,4 @@ class WonBlockRelayPlanner WonBlockRelay& m_relay; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/broadcaster.hpp b/src/impl/dash/broadcaster.hpp index 082684538..1eac7a0db 100644 --- a/src/impl/dash/broadcaster.hpp +++ b/src/impl/dash/broadcaster.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — DashBroadcaster: dashd P2P peer-pool + discovery scaffold (LEAF). @@ -349,4 +350,4 @@ class DashBroadcaster std::map m_backoff; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/broadcaster_full.hpp b/src/impl/dash/broadcaster_full.hpp index fc21cac15..ef568c1fe 100644 --- a/src/impl/dash/broadcaster_full.hpp +++ b/src/impl/dash/broadcaster_full.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — DashBroadcasterFull: the won-block KEYSTONE (dual-path #83). @@ -200,4 +201,4 @@ class DashBroadcasterFull RpcSubmitFn m_rpc_submit; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/chain_admit.hpp b/src/impl/dash/chain_admit.hpp index 0472db6e7..3c7def188 100644 --- a/src/impl/dash/chain_admit.hpp +++ b/src/impl/dash/chain_admit.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash chain-relative share admission seam. @@ -65,4 +66,4 @@ inline uint256 admit_share(const DashShare& share, ChainT& chain, return hash; } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/block.hpp b/src/impl/dash/coin/block.hpp index 4bdb98e9b..ac0646384 100644 --- a/src/impl/dash/coin/block.hpp +++ b/src/impl/dash/coin/block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash block types: standard Bitcoin 80-byte header, no MWEB. @@ -48,4 +49,4 @@ struct BlockType : BlockHeaderType }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/block_producer.hpp b/src/impl/dash/coin/block_producer.hpp index 1d128a732..48bc05e18 100644 --- a/src/impl/dash/coin/block_producer.hpp +++ b/src/impl/dash/coin/block_producer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -238,4 +239,4 @@ inline MineResult mine_block(const DashWorkData& work, } } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/chain_seeds.hpp b/src/impl/dash/coin/chain_seeds.hpp index ea9338bc0..b89c0fe13 100644 --- a/src/impl/dash/coin/chain_seeds.hpp +++ b/src/impl/dash/coin/chain_seeds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DNS seed hostnames and hardcoded fallback IPs for Dash P2P networks. @@ -404,4 +405,4 @@ inline std::vector dash_fixed_seeds(bool testnet) } } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/credit_pool.hpp b/src/impl/dash/coin/credit_pool.hpp index 77dfabdc6..ca075352d 100644 --- a/src/impl/dash/coin/credit_pool.hpp +++ b/src/impl/dash/coin/credit_pool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-TEMPLATE step 13: DIP-0027 credit-pool state machine. @@ -125,4 +126,4 @@ class CreditPool }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/credit_pool_db.hpp b/src/impl/dash/coin/credit_pool_db.hpp index 6f3c44fc9..89f913fba 100644 --- a/src/impl/dash/coin/credit_pool_db.hpp +++ b/src/impl/dash/coin/credit_pool_db.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-TEMPLATE step 13b: persistent CreditPool state. @@ -133,4 +134,4 @@ class CreditPoolDb }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/embedded_gbt.hpp b/src/impl/dash/coin/embedded_gbt.hpp index 938e85cd3..f6502c4c3 100644 --- a/src/impl/dash/coin/embedded_gbt.hpp +++ b/src/impl/dash/coin/embedded_gbt.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-TEMPLATE step 5: embedded GBT skeleton (S7 capstone). @@ -395,4 +396,4 @@ inline bool cbtx_xcheck(const vendor::CCbTx& embedded, } } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/header_chain.hpp b/src/impl/dash/coin/header_chain.hpp index 0a6a230d0..330ace253 100644 --- a/src/impl/dash/coin/header_chain.hpp +++ b/src/impl/dash/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Dash Header Chain — SPV header-only chain with X11 PoW validation. @@ -714,4 +715,4 @@ class HeaderChain { }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/mempool.hpp b/src/impl/dash/coin/mempool.hpp index fd5730bf8..807e638b4 100644 --- a/src/impl/dash/coin/mempool.hpp +++ b/src/impl/dash/coin/mempool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-MEMPOOL step 1: in-memory Dash mempool. @@ -506,4 +507,4 @@ class Mempool { }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/mn_state_db.hpp b/src/impl/dash/coin/mn_state_db.hpp index 6aa2a5e90..112c2ea90 100644 --- a/src/impl/dash/coin/mn_state_db.hpp +++ b/src/impl/dash/coin/mn_state_db.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-PAY step 2: per-MN state store. @@ -300,4 +301,4 @@ class MnStateDb }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/mn_state_machine.hpp b/src/impl/dash/coin/mn_state_machine.hpp index 75fc4824b..8cf773d54 100644 --- a/src/impl/dash/coin/mn_state_machine.hpp +++ b/src/impl/dash/coin/mn_state_machine.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-PAY step 4: per-block DMN state machine. @@ -665,4 +666,4 @@ class MnStateMachine }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/node_interface.hpp b/src/impl/dash/coin/node_interface.hpp index ffd677a97..5ce0491d2 100644 --- a/src/impl/dash/coin/node_interface.hpp +++ b/src/impl/dash/coin/node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "block.hpp" @@ -34,4 +35,4 @@ struct Node }; } // namespace interfaces -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/p2p_connection.hpp b/src/impl/dash/coin/p2p_connection.hpp index 6b05bb9c7..24d6707cb 100644 --- a/src/impl/dash/coin/p2p_connection.hpp +++ b/src/impl/dash/coin/p2p_connection.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — Dash coin-daemon P2P connection. @@ -93,4 +94,4 @@ class Connection } // namespace p2p } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/p2p_messages.hpp b/src/impl/dash/coin/p2p_messages.hpp index 7f6f7bd93..508d1185e 100644 --- a/src/impl/dash/coin/p2p_messages.hpp +++ b/src/impl/dash/coin/p2p_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash coin daemon P2P messages. @@ -204,4 +205,4 @@ using Handler = MessageHandler< } // namespace p2p } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/p2p_node.hpp b/src/impl/dash/coin/p2p_node.hpp index a3cc85e9d..5cf3cab43 100644 --- a/src/impl/dash/coin/p2p_node.hpp +++ b/src/impl/dash/coin/p2p_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase S8 — Dash coin-daemon P2P node (socket-node skeleton LEAF). @@ -189,4 +190,4 @@ class NodeP2P } // namespace p2p } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/quorum_manager.hpp b/src/impl/dash/coin/quorum_manager.hpp index 1e66f8893..d38ace694 100644 --- a/src/impl/dash/coin/quorum_manager.hpp +++ b/src/impl/dash/coin/quorum_manager.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // QuorumManager: in-memory tracker for the active LLMQ quorum set. @@ -218,4 +219,4 @@ class QuorumManager }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/quorum_root.hpp b/src/impl/dash/coin/quorum_root.hpp index 8fb4031b4..d8e6c3bd3 100644 --- a/src/impl/dash/coin/quorum_root.hpp +++ b/src/impl/dash/coin/quorum_root.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-TEMPLATE step 4c: vendor compute_merkle_root_quorums. @@ -169,4 +170,4 @@ inline uint256 compute_merkle_root_quorums(const QuorumManager& qmgr) } } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/rpc.cpp b/src/impl/dash/coin/rpc.cpp index 995de84ad..48ff5c52a 100644 --- a/src/impl/dash/coin/rpc.cpp +++ b/src/impl/dash/coin/rpc.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "rpc.hpp" #include @@ -446,4 +447,4 @@ nlohmann::json NodeRPC::getblock(uint256 blockhash, int verbosity) } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/rpc.hpp b/src/impl/dash/coin/rpc.hpp index 6e32ec3c3..bc4fb9305 100644 --- a/src/impl/dash/coin/rpc.hpp +++ b/src/impl/dash/coin/rpc.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -128,4 +129,4 @@ struct RPCAuthData } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/rpc_conf.hpp b/src/impl/dash/coin/rpc_conf.hpp index e7ac31fed..a830a35c9 100644 --- a/src/impl/dash/coin/rpc_conf.hpp +++ b/src/impl/dash/coin/rpc_conf.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -94,4 +95,4 @@ inline void apply_endpoint_override(const std::string& hostport, RpcConf& out) } } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/rpc_data.hpp b/src/impl/dash/coin/rpc_data.hpp index 76f041f96..0f2abc89c 100644 --- a/src/impl/dash/coin/rpc_data.hpp +++ b/src/impl/dash/coin/rpc_data.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Parsed getblocktemplate response with Dash-specific fields. @@ -93,4 +94,4 @@ struct DashWorkData { }; } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/rpc_request.hpp b/src/impl/dash/coin/rpc_request.hpp index 3b0b6d9fd..d66caddef 100644 --- a/src/impl/dash/coin/rpc_request.hpp +++ b/src/impl/dash/coin/rpc_request.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -86,4 +87,4 @@ inline const char* dash_genesis_hash(bool testnet) } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/subsidy.hpp b/src/impl/dash/coin/subsidy.hpp index 9b69beaf4..c192a812b 100644 --- a/src/impl/dash/coin/subsidy.hpp +++ b/src/impl/dash/coin/subsidy.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase C-TEMPLATE step 1: block-subsidy + MN-payment formula vendor. @@ -173,4 +174,4 @@ inline std::optional computed_block_fees( } } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/transaction.hpp b/src/impl/dash/coin/transaction.hpp index 3cb03805e..2e7dd5ca9 100644 --- a/src/impl/dash/coin/transaction.hpp +++ b/src/impl/dash/coin/transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash transaction types: standard Bitcoin transactions + DIP3/DIP4 CBTX support. @@ -116,4 +117,4 @@ inline MutableTransaction::MutableTransaction(const Transaction& tx) type(tx.type), locktime(tx.locktime), extra_payload(tx.extra_payload) {} } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/utxo_adapter.hpp b/src/impl/dash/coin/utxo_adapter.hpp index 23eb08203..daaa488a5 100644 --- a/src/impl/dash/coin/utxo_adapter.hpp +++ b/src/impl/dash/coin/utxo_adapter.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Dash UTXO adapter layer — Phase U step 1. @@ -102,4 +103,4 @@ static_assert(MutableTransaction::m_hogEx == false, "required by the shared UTXOViewCache::connect_block template)"); } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/assetlock.hpp b/src/impl/dash/coin/vendor/assetlock.hpp index fd6134d8c..354a9a6a2 100644 --- a/src/impl/dash/coin/vendor/assetlock.hpp +++ b/src/impl/dash/coin/vendor/assetlock.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Vendored from dashcore/src/evo/assetlocktx.h @ develop cfad414 @@ -151,4 +152,4 @@ inline bool parse_assetunlock_payload( } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/blockencodings.cpp b/src/impl/dash/coin/vendor/blockencodings.cpp index e49fe1c22..2e2a7a087 100644 --- a/src/impl/dash/coin/vendor/blockencodings.cpp +++ b/src/impl/dash/coin/vendor/blockencodings.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Copyright (c) 2016-2020 The Bitcoin Core developers // Copyright (c) 2020-2026 The Dash Core developers // Distributed under the MIT software license, see the accompanying @@ -228,4 +229,4 @@ ReadStatus PartiallyDownloadedBlock::FillBlock(CBlock& block, const std::vector< } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/blockencodings.hpp b/src/impl/dash/coin/vendor/blockencodings.hpp index c30199302..9df263ea1 100644 --- a/src/impl/dash/coin/vendor/blockencodings.hpp +++ b/src/impl/dash/coin/vendor/blockencodings.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Copyright (c) 2016-2020 The Bitcoin Core developers // Copyright (c) 2020-2026 The Dash Core developers // Distributed under the MIT software license, see the accompanying @@ -169,4 +170,4 @@ class PartiallyDownloadedBlock { } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/cbtx.hpp b/src/impl/dash/coin/vendor/cbtx.hpp index ef40f508e..60fb093f2 100644 --- a/src/impl/dash/coin/vendor/cbtx.hpp +++ b/src/impl/dash/coin/vendor/cbtx.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Vendored from dashcore/src/evo/cbtx.h @ develop cfad414 @@ -122,4 +123,4 @@ inline bool parse_cbtx(const std::vector& extra_payload, CCbTx& o } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/llmq_commitment.hpp b/src/impl/dash/coin/vendor/llmq_commitment.hpp index f8be5500c..f260eaf18 100644 --- a/src/impl/dash/coin/vendor/llmq_commitment.hpp +++ b/src/impl/dash/coin/vendor/llmq_commitment.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Vendored from dashcore/src/llmq/commitment.h @ develop cfad414 @@ -213,4 +214,4 @@ inline bool parse_qfcommit_payload(const std::vector& bytes, } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/providertx.hpp b/src/impl/dash/coin/vendor/providertx.hpp index c393d1200..eacbb5685 100644 --- a/src/impl/dash/coin/vendor/providertx.hpp +++ b/src/impl/dash/coin/vendor/providertx.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Vendored from dashcore/src/evo/providertx.{h,cpp} @ develop cfad414 @@ -371,4 +372,4 @@ inline bool parse_protx_payload(const std::vector& payload, T& out) } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/quorum_tail.hpp b/src/impl/dash/coin/vendor/quorum_tail.hpp index f07da78e8..4700878b1 100644 --- a/src/impl/dash/coin/vendor/quorum_tail.hpp +++ b/src/impl/dash/coin/vendor/quorum_tail.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase C-QUO step 2: structured parser for the mnlistdiff "quorum tail" @@ -135,4 +136,4 @@ inline bool parse_quorum_tail(const std::vector& bytes, } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/shim.hpp b/src/impl/dash/coin/vendor/shim.hpp index a10cf8908..92d791655 100644 --- a/src/impl/dash/coin/vendor/shim.hpp +++ b/src/impl/dash/coin/vendor/shim.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Adapter shim mapping dashcore's blockencodings type names and custom @@ -193,4 +194,4 @@ struct DifferenceListFormat } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/simplifiedmns.hpp b/src/impl/dash/coin/vendor/simplifiedmns.hpp index 3aead0890..43c91eea1 100644 --- a/src/impl/dash/coin/vendor/simplifiedmns.hpp +++ b/src/impl/dash/coin/vendor/simplifiedmns.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Vendored from dashcore/src/evo/simplifiedmns.{h,cpp} @ develop cfad414 @@ -306,4 +307,4 @@ class CSimplifiedMNList } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coin/vendor/smldiff.hpp b/src/impl/dash/coin/vendor/smldiff.hpp index 1d1534e10..dad2d5e81 100644 --- a/src/impl/dash/coin/vendor/smldiff.hpp +++ b/src/impl/dash/coin/vendor/smldiff.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Vendored from dashcore/src/evo/smldiff.h @ develop cfad414 @@ -167,4 +168,4 @@ inline ApplyDiffResult apply_diff(CSimplifiedMNList& current, } // namespace vendor } // namespace coin -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/coinbase_builder.hpp b/src/impl/dash/coinbase_builder.hpp index a599563ba..0da8668c3 100644 --- a/src/impl/dash/coinbase_builder.hpp +++ b/src/impl/dash/coinbase_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash coinbase TX assembly for p2pool-dash v16 compatible Stratum mining. @@ -491,4 +492,4 @@ inline std::string be_hex_u32(uint32_t v) } } // namespace coinbase -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/config.hpp b/src/impl/dash/config.hpp index c59716f51..05efe156c 100644 --- a/src/impl/dash/config.hpp +++ b/src/impl/dash/config.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash configuration types. @@ -53,4 +54,4 @@ class CoinConfig : protected core::Fileconfig // Combined config using Config = core::Config; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/config_pool.hpp b/src/impl/dash/config_pool.hpp index 843edaf9b..d27be3044 100644 --- a/src/impl/dash/config_pool.hpp +++ b/src/impl/dash/config_pool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DASH P2Pool sharechain network configuration (oracle-sourced SSOT). @@ -114,4 +115,4 @@ struct SharechainConfig static uint256 sane_target_max() { return max_target(); } }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/crypto/hash_x11.hpp b/src/impl/dash/crypto/hash_x11.hpp index 28a5c0297..40bb4e233 100644 --- a/src/impl/dash/crypto/hash_x11.hpp +++ b/src/impl/dash/crypto/hash_x11.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // X11 hash algorithm for Dash PoW. @@ -120,4 +121,4 @@ inline uint256 hash_x11(std::span data) } } // namespace crypto -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_blake.h b/src/impl/dash/crypto/x11/sph_blake.h index d8d794399..c6dbcf1dd 100644 --- a/src/impl/dash/crypto/x11/sph_blake.h +++ b/src/impl/dash/crypto/x11/sph_blake.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_blake.h 252 2011-06-07 17:55:14Z tp $ */ /** * BLAKE interface. BLAKE is a family of functions which differ by their @@ -324,4 +325,4 @@ void sph_blake512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_bmw.h b/src/impl/dash/crypto/x11/sph_bmw.h index d386b0c14..9595c01e9 100644 --- a/src/impl/dash/crypto/x11/sph_bmw.h +++ b/src/impl/dash/crypto/x11/sph_bmw.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_bmw.h 216 2010-06-08 09:46:57Z tp $ */ /** * BMW interface. BMW (aka "Blue Midnight Wish") is a family of @@ -325,4 +326,4 @@ void sph_bmw512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_cubehash.h b/src/impl/dash/crypto/x11/sph_cubehash.h index 487a1946a..f79c5e0e3 100644 --- a/src/impl/dash/crypto/x11/sph_cubehash.h +++ b/src/impl/dash/crypto/x11/sph_cubehash.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_cubehash.h 180 2010-05-08 02:29:25Z tp $ */ /** * CubeHash interface. CubeHash is a family of functions which differ by @@ -289,4 +290,4 @@ void sph_cubehash512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_echo.h b/src/impl/dash/crypto/x11/sph_echo.h index 1ae1e3dd6..0885eeca7 100644 --- a/src/impl/dash/crypto/x11/sph_echo.h +++ b/src/impl/dash/crypto/x11/sph_echo.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_echo.h 216 2010-06-08 09:46:57Z tp $ */ /** * ECHO interface. ECHO is a family of functions which differ by @@ -317,4 +318,4 @@ void sph_echo512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_groestl.h b/src/impl/dash/crypto/x11/sph_groestl.h index 495f05e21..bc0e3da58 100644 --- a/src/impl/dash/crypto/x11/sph_groestl.h +++ b/src/impl/dash/crypto/x11/sph_groestl.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_groestl.h 216 2010-06-08 09:46:57Z tp $ */ /** * Groestl interface. This code implements Groestl with the recommended @@ -326,4 +327,4 @@ void sph_groestl512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_jh.h b/src/impl/dash/crypto/x11/sph_jh.h index 82fae58df..f2006b9a2 100644 --- a/src/impl/dash/crypto/x11/sph_jh.h +++ b/src/impl/dash/crypto/x11/sph_jh.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_jh.h 216 2010-06-08 09:46:57Z tp $ */ /** * JH interface. JH is a family of functions which differ by @@ -295,4 +296,4 @@ void sph_jh512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_keccak.h b/src/impl/dash/crypto/x11/sph_keccak.h index bdafdb88d..34ecd5a52 100644 --- a/src/impl/dash/crypto/x11/sph_keccak.h +++ b/src/impl/dash/crypto/x11/sph_keccak.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_keccak.h 216 2010-06-08 09:46:57Z tp $ */ /** * Keccak interface. This is the interface for Keccak with the @@ -290,4 +291,4 @@ void sph_keccak512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_luffa.h b/src/impl/dash/crypto/x11/sph_luffa.h index a32fd7b16..58c1f23c3 100644 --- a/src/impl/dash/crypto/x11/sph_luffa.h +++ b/src/impl/dash/crypto/x11/sph_luffa.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_luffa.h 154 2010-04-26 17:00:24Z tp $ */ /** * Luffa interface. Luffa is a family of functions which differ by @@ -293,4 +294,4 @@ void sph_luffa512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_shavite.h b/src/impl/dash/crypto/x11/sph_shavite.h index 0957e42a9..b88fe0cc6 100644 --- a/src/impl/dash/crypto/x11/sph_shavite.h +++ b/src/impl/dash/crypto/x11/sph_shavite.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_shavite.h 208 2010-06-02 20:33:00Z tp $ */ /** * SHAvite-3 interface. This code implements SHAvite-3 with the @@ -311,4 +312,4 @@ void sph_shavite512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_simd.h b/src/impl/dash/crypto/x11/sph_simd.h index 92ee1e727..ec0b46727 100644 --- a/src/impl/dash/crypto/x11/sph_simd.h +++ b/src/impl/dash/crypto/x11/sph_simd.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_simd.h 154 2010-04-26 17:00:24Z tp $ */ /** * SIMD interface. SIMD is a family of functions which differ by @@ -306,4 +307,4 @@ void sph_simd512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_skein.h b/src/impl/dash/crypto/x11/sph_skein.h index bddbc86fa..82f904347 100644 --- a/src/impl/dash/crypto/x11/sph_skein.h +++ b/src/impl/dash/crypto/x11/sph_skein.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_skein.h 253 2011-06-07 18:33:10Z tp $ */ /** * Skein interface. The Skein specification defines three main @@ -295,4 +296,4 @@ void sph_skein512_addbits_and_close( } #endif -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/crypto/x11/sph_types.h b/src/impl/dash/crypto/x11/sph_types.h index 7295b0b37..4aede1c0e 100644 --- a/src/impl/dash/crypto/x11/sph_types.h +++ b/src/impl/dash/crypto/x11/sph_types.h @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* $Id: sph_types.h 260 2011-07-21 01:02:38Z tp $ */ /** * Basic type definitions. @@ -1973,4 +1974,4 @@ sph_dec64le_aligned(const void *src) #endif /* Doxygen excluded block */ -#endif +#endif \ No newline at end of file diff --git a/src/impl/dash/messages.hpp b/src/impl/dash/messages.hpp index 8b09dbd3b..e5f4ea64a 100644 --- a/src/impl/dash/messages.hpp +++ b/src/impl/dash/messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // V36 Dash-X11 sharechain pool wire-message layer — namespace-only divergence @@ -195,4 +196,4 @@ using Handler = MessageHandler< message_remember_tx >; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/min_protocol_gate.hpp b/src/impl/dash/min_protocol_gate.hpp index 0ff10c30f..2317a43c2 100644 --- a/src/impl/dash/min_protocol_gate.hpp +++ b/src/impl/dash/min_protocol_gate.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DASH sharechain minimum-protocol-version gate (v36 min-proto ratchet, #643). @@ -50,4 +51,4 @@ struct MinProtocolGate } }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/node.cpp b/src/impl/dash/node.cpp index 6f61b9b8c..a72873b65 100644 --- a/src/impl/dash/node.cpp +++ b/src/impl/dash/node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" @@ -192,4 +193,4 @@ NodeImpl::handle_get_share(std::vector hashes, uint64_t parents, return shares; } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/node.hpp b/src/impl/dash/node.hpp index 1d802321b..242437241 100644 --- a/src/impl/dash/node.hpp +++ b/src/impl/dash/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash p2pool sharechain pool-node — S8 pool-node leaf 5 (FINAL), slice A. @@ -464,4 +465,4 @@ class Actual : public pool::Protocol using Node = pool::NodeBridge; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/params.hpp b/src/impl/dash/params.hpp index 56d14ea70..5ca15e177 100644 --- a/src/impl/dash/params.hpp +++ b/src/impl/dash/params.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DASH CoinParams factory: builds a fully populated core::CoinParams for the @@ -145,4 +146,4 @@ inline core::CoinParams make_coin_params(bool testnet) return make_coin_params(testnet, PoolOverrides{}); } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/peer.hpp b/src/impl/dash/peer.hpp index 7c4aa958d..7be9b0916 100644 --- a/src/impl/dash/peer.hpp +++ b/src/impl/dash/peer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash p2pool sharechain pool-peer state. @@ -40,4 +41,4 @@ struct Peer std::map m_remembered_txs; // full txs keyed by hash }; -}; // namespace dash +}; // namespace dash \ No newline at end of file diff --git a/src/impl/dash/pplns.hpp b/src/impl/dash/pplns.hpp index b1a88f510..1817ed2bc 100644 --- a/src/impl/dash/pplns.hpp +++ b/src/impl/dash/pplns.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // PPLNS payout computation for c2pool-dash. @@ -189,4 +190,4 @@ inline Result compute_payouts( } } // namespace pplns -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/protocol_actual.cpp b/src/impl/dash/protocol_actual.cpp index 29fbcb4d1..2aa8be805 100644 --- a/src/impl/dash/protocol_actual.cpp +++ b/src/impl/dash/protocol_actual.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" @@ -271,4 +272,4 @@ void Actual::HANDLER(forget_tx) } } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/protocol_legacy.cpp b/src/impl/dash/protocol_legacy.cpp index e6ce04abc..102fde7a3 100644 --- a/src/impl/dash/protocol_legacy.cpp +++ b/src/impl/dash/protocol_legacy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" diff --git a/src/impl/dash/share.hpp b/src/impl/dash/share.hpp index 36092d5b9..7f85ad1c7 100644 --- a/src/impl/dash/share.hpp +++ b/src/impl/dash/share.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash p2pool Share v16. @@ -65,4 +66,4 @@ struct DashShare : chain::BaseShare NetService peer_addr; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/share_chain.hpp b/src/impl/dash/share_chain.hpp index 80e8f6caa..d090b9459 100644 --- a/src/impl/dash/share_chain.hpp +++ b/src/impl/dash/share_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash share chain types: ShareType variant, ShareIndex, ShareChain. @@ -243,4 +244,4 @@ struct ShareChain : chain::ShareChain { }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/share_check.hpp b/src/impl/dash/share_check.hpp index c2c2de90f..54e5e8f47 100644 --- a/src/impl/dash/share_check.hpp +++ b/src/impl/dash/share_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash share v16 verification: hash_link, merkle, X11 PoW. @@ -855,4 +856,4 @@ inline uint256 verify_share(const DashShare& share, ChainT& chain, verify_version_transition(share, chain, chain_length); // Phase 2 (wired gate) return hash; } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/share_messages.hpp b/src/impl/dash/share_messages.hpp index 688d87242..8b6472b21 100644 --- a/src/impl/dash/share_messages.hpp +++ b/src/impl/dash/share_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // share_messages.hpp — V36 share-embedded messaging: decryption + validation // // Port of p2pool/share_messages.py (consensus-critical portions). @@ -580,4 +581,4 @@ inline std::vector create_message_data( return encrypt_message_envelope(inner, authority_pubkey); } -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/share_tracker.hpp b/src/impl/dash/share_tracker.hpp index da5303307..83f09d501 100644 --- a/src/impl/dash/share_tracker.hpp +++ b/src/impl/dash/share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Portable 128-bit multiply-shift: (a * b) >> shift @@ -2884,4 +2885,4 @@ class ShareTracker CumulativeWeights m_decayed_cache_result; }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/share_types.hpp b/src/impl/dash/share_types.hpp index e54f90af7..aa6214412 100644 --- a/src/impl/dash/share_types.hpp +++ b/src/impl/dash/share_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash p2pool share v16 serialization types. @@ -64,4 +65,4 @@ struct PackedPayment } }; -} // namespace dash +} // namespace dash \ No newline at end of file diff --git a/src/impl/dash/stratum/work_job_targets.hpp b/src/impl/dash/stratum/work_job_targets.hpp index a8484b36b..63a45e829 100644 --- a/src/impl/dash/stratum/work_job_targets.hpp +++ b/src/impl/dash/stratum/work_job_targets.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // dash::stratum::* — get_work() JOB-TARGET assembly (S8 get_work() wiring). @@ -106,4 +107,4 @@ inline WorkJobTargets assemble_work_job_targets(const WorkJobTargetInputs& in) return WorkJobTargets{ floor, target }; } -} // namespace dash::stratum +} // namespace dash::stratum \ No newline at end of file diff --git a/src/impl/dash/stratum/work_target.hpp b/src/impl/dash/stratum/work_target.hpp index eb27096fc..a48e33dde 100644 --- a/src/impl/dash/stratum/work_target.hpp +++ b/src/impl/dash/stratum/work_target.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // dash::stratum::* — per-miner work-target MODULATION accessor (S8). @@ -165,4 +166,4 @@ inline uint256 modulate_desired_share_target(const WorkTargetInputs& in) return desired; } -} // namespace dash::stratum +} // namespace dash::stratum \ No newline at end of file diff --git a/src/impl/dash/version_activation_latch.hpp b/src/impl/dash/version_activation_latch.hpp index 979df5e18..1c6927e8f 100644 --- a/src/impl/dash/version_activation_latch.hpp +++ b/src/impl/dash/version_activation_latch.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash v36 activation LATCH — the persisted VOTING -> ACTIVATED -> CONFIRMED @@ -124,4 +125,4 @@ struct ActivationLatch } }; -} // namespace dash::version_activation_latch +} // namespace dash::version_activation_latch \ No newline at end of file diff --git a/src/impl/dash/version_negotiation.hpp b/src/impl/dash/version_negotiation.hpp index 57f5afb0d..1f6d13be0 100644 --- a/src/impl/dash/version_negotiation.hpp +++ b/src/impl/dash/version_negotiation.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Dash share-version transition negotiation (older-than-v35 -> v36). @@ -242,4 +243,4 @@ switch_accepted(SwitchClass cls, bool gate_cleared) return false; } -} // namespace dash::version_negotiation +} // namespace dash::version_negotiation \ No newline at end of file diff --git a/src/impl/dgb/auto_ratchet.hpp b/src/impl/dgb/auto_ratchet.hpp index b03574d2c..5048df8c5 100644 --- a/src/impl/dgb/auto_ratchet.hpp +++ b/src/impl/dgb/auto_ratchet.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // AutoRatchet: autonomous share version transition state machine (DGB port). @@ -357,4 +358,4 @@ class AutoRatchet } }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/auto_ratchet_tail_guard.hpp b/src/impl/dgb/auto_ratchet_tail_guard.hpp index 4dea761f6..36a54adb4 100644 --- a/src/impl/dgb/auto_ratchet_tail_guard.hpp +++ b/src/impl/dgb/auto_ratchet_tail_guard.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // AutoRatchet tail-guard SSOT (DGB Phase-B conformance pillar). @@ -84,4 +85,4 @@ inline bool tail_guard_passes(const WeightMap& weights, int64_t target_version, return switched(tt.first, tt.second, switch_threshold); } -} // namespace dgb::auto_ratchet +} // namespace dgb::auto_ratchet \ No newline at end of file diff --git a/src/impl/dgb/auto_ratchet_wire.hpp b/src/impl/dgb/auto_ratchet_wire.hpp index 5c9ba253c..b47d9ccb4 100644 --- a/src/impl/dgb/auto_ratchet_wire.hpp +++ b/src/impl/dgb/auto_ratchet_wire.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // auto_ratchet_wire.hpp — DGB production wire-in for the AutoRatchet mint-side @@ -59,4 +60,4 @@ inline std::pair dgb_select_mint_versions( return ratchet.get_share_version(tracker, best_share_hash); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_broadcast_path_election.hpp b/src/impl/dgb/coin/aux_broadcast_path_election.hpp index 3dc8d164b..ac1273829 100644 --- a/src/impl/dgb/coin/aux_broadcast_path_election.hpp +++ b/src/impl/dgb/coin/aux_broadcast_path_election.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE (phase DC) — broadcast-path ELECTION + single-fire ledger. // @@ -109,4 +110,4 @@ inline AuxBroadcastPath elect_and_claim(AuxBroadcastLedger& ledger, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_chain_embedded.hpp b/src/impl/dgb/coin/aux_chain_embedded.hpp index 2b88bb31b..e9cff6e88 100644 --- a/src/impl/dgb/coin/aux_chain_embedded.hpp +++ b/src/impl/dgb/coin/aux_chain_embedded.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // =========================================================================== // dgb::coin::AuxChainEmbedded -- DGB's OWN embedded merged-mining backend. @@ -181,4 +182,4 @@ class AuxChainEmbedded : public c2pool::merged::IAuxChainBackend } // namespace coin } // namespace dgb -#endif // AUX_DOGE +#endif // AUX_DOGE \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_doge_isolation_guard.hpp b/src/impl/dgb/coin/aux_doge_isolation_guard.hpp index 6ce7ca355..db22f9ec2 100644 --- a/src/impl/dgb/coin/aux_doge_isolation_guard.hpp +++ b/src/impl/dgb/coin/aux_doge_isolation_guard.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (D0.5) -- per-coin consensus-isolation guard. @@ -65,4 +66,4 @@ static_assert( } // namespace dgb::coin::aux_doge_guard -#endif // AUX_DOGE +#endif // AUX_DOGE \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_doge_mm_commitment.hpp b/src/impl/dgb/coin/aux_doge_mm_commitment.hpp index c88dc083f..d8b7fa366 100644 --- a/src/impl/dgb/coin/aux_doge_mm_commitment.hpp +++ b/src/impl/dgb/coin/aux_doge_mm_commitment.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DB) -- DGB-side AuxPoW coinbase-commitment @@ -69,4 +70,4 @@ inline std::vector build_aux_mm_commitment( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_doge_parent_traits.hpp b/src/impl/dgb/coin/aux_doge_parent_traits.hpp index a862ec074..2a5403da9 100644 --- a/src/impl/dgb/coin/aux_doge_parent_traits.hpp +++ b/src/impl/dgb/coin/aux_doge_parent_traits.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DB) — DGB-as-PARENT trait specialization. @@ -33,4 +34,4 @@ struct parent_coinbase_no_witness static constexpr auto value = dgb::coin::TX_NO_WITNESS; }; -} // namespace doge::coin +} // namespace doge::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_doge_submit.hpp b/src/impl/dgb/coin/aux_doge_submit.hpp index eedbfae46..b8acdd180 100644 --- a/src/impl/dgb/coin/aux_doge_submit.hpp +++ b/src/impl/dgb/coin/aux_doge_submit.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin -- DOGE-aux won-block SUBMIT half (phase DC, -DAUX_DOGE=ON only). @@ -132,4 +133,4 @@ make_aux_doge_on_block_found(AuxDogeBlockAssembler assemble, } // namespace coin } // namespace dgb -#endif // AUX_DOGE +#endif // AUX_DOGE \ No newline at end of file diff --git a/src/impl/dgb/coin/aux_dual_target_select.hpp b/src/impl/dgb/coin/aux_dual_target_select.hpp index f05d64442..5e6898a9a 100644 --- a/src/impl/dgb/coin/aux_dual_target_select.hpp +++ b/src/impl/dgb/coin/aux_dual_target_select.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DC) — dual-target SELECTION scaffold. @@ -77,4 +78,4 @@ inline bool selection_is_consistent(const AuxMintDecision& mint, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/binomial_conf_interval.hpp b/src/impl/dgb/coin/binomial_conf_interval.hpp index c98e63338..e17200cda 100644 --- a/src/impl/dgb/coin/binomial_conf_interval.hpp +++ b/src/impl/dgb/coin/binomial_conf_interval.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::binomial_conf_interval -- FENCED, additive SSOT lift of the @@ -93,4 +94,4 @@ inline std::array binomial_conf_interval(double x, double n, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/block.hpp b/src/impl/dgb/coin/block.hpp index 29ca418e5..826661058 100644 --- a/src/impl/dgb/coin/block.hpp +++ b/src/impl/dgb/coin/block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB block/header types. 1:1 mirror of src/impl/btc/coin/block.hpp (NON-MWEB). diff --git a/src/impl/dgb/coin/block_assembly.hpp b/src/impl/dgb/coin/block_assembly.hpp index 874bfe307..2043cfdb9 100644 --- a/src/impl/dgb/coin/block_assembly.hpp +++ b/src/impl/dgb/coin/block_assembly.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::assemble_won_block -- the share->block "as_block" reassembly that @@ -157,4 +158,4 @@ assemble_won_block(const SmallBlockHeaderType& small_header, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/block_broadcast.hpp b/src/impl/dgb/coin/block_broadcast.hpp index 0a83ec215..d2305f8dd 100644 --- a/src/impl/dgb/coin/block_broadcast.hpp +++ b/src/impl/dgb/coin/block_broadcast.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::broadcast_won_block -- the DGB dual-path won-block dispatcher. @@ -126,4 +127,4 @@ inline BlockBroadcast broadcast_won_block(const P2pRelaySink& p2p_relay, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/chain_walk_window.hpp b/src/impl/dgb/coin/chain_walk_window.hpp index 8327bb0c4..8a5ec33c4 100644 --- a/src/impl/dgb/coin/chain_walk_window.hpp +++ b/src/impl/dgb/coin/chain_walk_window.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB LOOKBEHIND chain-walk WINDOW clamp -- the pure integer guard @@ -75,4 +76,4 @@ inline bool chain_walk_window_active(int32_t actual) return actual > 0; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/coin_node.cpp b/src/impl/dgb/coin/coin_node.cpp index b8446485b..f104bf988 100644 --- a/src/impl/dgb/coin/coin_node.cpp +++ b/src/impl/dgb/coin/coin_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "coin_node.hpp" #include @@ -48,4 +49,4 @@ bool CoinNode::submit_block_hex(const std::string& block_hex, bool ignore_failur } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/coin_node.hpp b/src/impl/dgb/coin/coin_node.hpp index 59a22d06e..61ef82e5d 100644 --- a/src/impl/dgb/coin/coin_node.hpp +++ b/src/impl/dgb/coin/coin_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -67,4 +68,4 @@ class CoinNode : public core::coin::ICoinNode } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/compact_blocks.hpp b/src/impl/dgb/coin/compact_blocks.hpp index 5b3a96928..96b39179e 100644 --- a/src/impl/dgb/coin/compact_blocks.hpp +++ b/src/impl/dgb/coin/compact_blocks.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB BIP152 compact blocks. 1:1 mirror of src/impl/btc/coin/compact_blocks.hpp @@ -319,4 +320,4 @@ inline CompactBlockReconstructionResult ReconstructBlock( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/connection_coinbase.hpp b/src/impl/dgb/coin/connection_coinbase.hpp index e6bb89666..67a4f5959 100644 --- a/src/impl/dgb/coin/connection_coinbase.hpp +++ b/src/impl/dgb/coin/connection_coinbase.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ============================================================================ // connection_coinbase.hpp — per-connection Stratum coinbase assembler + split. @@ -169,4 +170,4 @@ inline ConnCoinbaseParts build_connection_coinbase_from_pplns(const ConnCoinbase return build_connection_coinbase_parts(ci); } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/desired_version_tally.hpp b/src/impl/dgb/coin/desired_version_tally.hpp index 4fd6d6753..3d3c53046 100644 --- a/src/impl/dgb/coin/desired_version_tally.hpp +++ b/src/impl/dgb/coin/desired_version_tally.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB DESIRED-VERSION TALLY -- the pure accumulation core of @@ -157,4 +158,4 @@ inline uint32_t apply_min_protocol_ratchet_decision( window_weights, best_version, current_floor, target_floor); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/dgb_arith256.hpp b/src/impl/dgb/coin/dgb_arith256.hpp index 803a581eb..ec34b09f5 100644 --- a/src/impl/dgb/coin/dgb_arith256.hpp +++ b/src/impl/dgb/coin/dgb_arith256.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB DigiShield retarget arithmetic at TRUE 256-bit width (M3 §7b). @@ -129,4 +130,4 @@ inline u256 mul_div_u256(const u256& avg, uint64_t mul, uint64_t div) { return avg.mul_u64(mul).div_u64(div); } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/dgb_block_algo.hpp b/src/impl/dgb/coin/dgb_block_algo.hpp index d44db0112..bd221215d 100644 --- a/src/impl/dgb/coin/dgb_block_algo.hpp +++ b/src/impl/dgb/coin/dgb_block_algo.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB multi-algo block-version classifier (M3 §7b — SCRYPT-ONLY VALIDATION). @@ -91,4 +92,4 @@ inline HeaderDisposition dgb_header_disposition(int32_t n_version) noexcept } } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/dgb_digishield.hpp b/src/impl/dgb/coin/dgb_digishield.hpp index 1c5a8e9dd..9ec3f746d 100644 --- a/src/impl/dgb/coin/dgb_digishield.hpp +++ b/src/impl/dgb/coin/dgb_digishield.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB DigiShield Scrypt-only ancestor walk (M3 §7b — SCRYPT-ONLY VALIDATION). @@ -70,4 +71,4 @@ inline std::vector scrypt_window_ancestors( return out; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/embedded_coin_node.hpp b/src/impl/dgb/coin/embedded_coin_node.hpp index b070e473e..ddd1f8a5f 100644 --- a/src/impl/dgb/coin/embedded_coin_node.hpp +++ b/src/impl/dgb/coin/embedded_coin_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // =========================================================================== // dgb::coin::EmbeddedCoinNode -- embedded (no external digibyted) work source. @@ -152,4 +153,4 @@ class EmbeddedCoinNode : public CoinNodeInterface EmbeddedTxSource m_tx_source; }; -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/embedded_coinbase_value.hpp b/src/impl/dgb/coin/embedded_coinbase_value.hpp index 48d0457bd..16a4c42e5 100644 --- a/src/impl/dgb/coin/embedded_coinbase_value.hpp +++ b/src/impl/dgb/coin/embedded_coinbase_value.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ============================================================================ // embedded_coinbase_value.hpp — SSOT for the embedded-path coinbase value. @@ -72,4 +73,4 @@ inline uint64_t resolve_coinbase_value(const core::SubsidyFunc& subsidy_func, return embedded_coinbase_value(subsidy_func, height, total_fees); } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/embedded_tx_select.cpp b/src/impl/dgb/coin/embedded_tx_select.cpp index 1f04f531e..7fa644ff3 100644 --- a/src/impl/dgb/coin/embedded_tx_select.cpp +++ b/src/impl/dgb/coin/embedded_tx_select.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // =========================================================================== // embedded_tx_select.cpp -- out-of-line shaper for the embedded tx source. // @@ -61,4 +62,4 @@ EmbeddedTxSource make_mempool_tx_source(Mempool& pool, uint32_t max_weight) }; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/embedded_tx_select.hpp b/src/impl/dgb/coin/embedded_tx_select.hpp index cfbc662d9..92608248f 100644 --- a/src/impl/dgb/coin/embedded_tx_select.hpp +++ b/src/impl/dgb/coin/embedded_tx_select.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // =========================================================================== // embedded_tx_select.hpp -- production EmbeddedTxSource factory. @@ -37,4 +38,4 @@ namespace dgb::coin // embedded node and its mempool share a lifetime). EmbeddedTxSource make_mempool_tx_source(Mempool& pool, uint32_t max_weight); -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/gentx_coinbase.hpp b/src/impl/dgb/coin/gentx_coinbase.hpp index 20a15d466..15a3d1418 100644 --- a/src/impl/dgb/coin/gentx_coinbase.hpp +++ b/src/impl/dgb/coin/gentx_coinbase.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ============================================================================ // gentx_coinbase.hpp — SSOT non-witness coinbase (gentx) assembler. @@ -128,4 +129,4 @@ inline GentxCoinbase assemble_gentx_coinbase( return out; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/gentx_unpack.hpp b/src/impl/dgb/coin/gentx_unpack.hpp index 2c4753779..7c98a38ba 100644 --- a/src/impl/dgb/coin/gentx_unpack.hpp +++ b/src/impl/dgb/coin/gentx_unpack.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::unpack_gentx_coinbase -- the INVERSE of #173's GentxCoinbase @@ -90,4 +91,4 @@ unpack_gentx_coinbase(const std::vector& gentx_bytes) } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/get_height_and_last_endpoints.hpp b/src/impl/dgb/coin/get_height_and_last_endpoints.hpp index 4cde24cda..ca7206ab0 100644 --- a/src/impl/dgb/coin/get_height_and_last_endpoints.hpp +++ b/src/impl/dgb/coin/get_height_and_last_endpoints.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB GET_HEIGHT_AND_LAST chain-walk endpoints -- the pure integer @@ -110,4 +111,4 @@ inline bool monitor_cycle_runs(int32_t height) return height >= MONITOR_MIN_HEIGHT; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/hash_format.hpp b/src/impl/dgb/coin/hash_format.hpp index 641856d43..8808e8d81 100644 --- a/src/impl/dgb/coin/hash_format.hpp +++ b/src/impl/dgb/coin/hash_format.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::u256_be_display_hex -- SSOT for rendering a u256 as the @@ -38,4 +39,4 @@ inline std::string u256_be_display_hex(const u256& v) return out; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/header_chain.hpp b/src/impl/dgb/coin/header_chain.hpp index 57ad0df41..a08ffe013 100644 --- a/src/impl/dgb/coin/header_chain.hpp +++ b/src/impl/dgb/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB header-chain validation. Mirrors src/impl/btc/coin/header_chain.hpp, // shares the Scrypt PoW path with src/impl/ltc (identical Scrypt to LTC). @@ -439,4 +440,4 @@ class HeaderChain { uint64_t m_cumulative_work = 0; }; -} // namespace c2pool::dgb +} // namespace c2pool::dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/header_ingest.hpp b/src/impl/dgb/coin/header_ingest.hpp index 80e143803..69359b9eb 100644 --- a/src/impl/dgb/coin/header_ingest.hpp +++ b/src/impl/dgb/coin/header_ingest.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // =========================================================================== // c2pool::dgb::wire_header_ingest -- connect the embedded P2P header-download @@ -55,4 +56,4 @@ wire_header_ingest(::dgb::interfaces::Node& node, HeaderChain& chain) }); } -} // namespace c2pool::dgb +} // namespace c2pool::dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/header_sample_build.hpp b/src/impl/dgb/coin/header_sample_build.hpp index 145db1614..8fdfa1cb2 100644 --- a/src/impl/dgb/coin/header_sample_build.hpp +++ b/src/impl/dgb/coin/header_sample_build.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // c2pool::dgb::make_header_sample -- embedded-ingest SSOT that builds a @@ -121,4 +122,4 @@ inline HeaderSample make_header_sample(const ::dgb::coin::BlockHeaderType& h) return s; } -} // namespace c2pool::dgb +} // namespace c2pool::dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/last_txout_nonce.hpp b/src/impl/dgb/coin/last_txout_nonce.hpp index c5b01af04..a09e89590 100644 --- a/src/impl/dgb/coin/last_txout_nonce.hpp +++ b/src/impl/dgb/coin/last_txout_nonce.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT: last_txout_nonce generation for the OP_RETURN extranonce slot. @@ -28,4 +29,4 @@ inline uint64_t make_last_txout_nonce() return rng(); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/mempool.hpp b/src/impl/dgb/coin/mempool.hpp index 820dca768..136c35966 100644 --- a/src/impl/dgb/coin/mempool.hpp +++ b/src/impl/dgb/coin/mempool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB embedded mempool. 1:1 mirror of src/impl/btc/coin/mempool.hpp (NON-MWEB). @@ -734,4 +735,4 @@ class Mempool { }; } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/mempool_ingest.hpp b/src/impl/dgb/coin/mempool_ingest.hpp index ef42ad7c1..eaf1c0998 100644 --- a/src/impl/dgb/coin/mempool_ingest.hpp +++ b/src/impl/dgb/coin/mempool_ingest.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // =========================================================================== // c2pool::dgb::wire_mempool_ingest -- connect the embedded P2P transaction @@ -61,4 +62,4 @@ wire_mempool_ingest(::dgb::interfaces::Node& node, ::dgb::coin::Mempool& pool) }); } -} // namespace c2pool::dgb +} // namespace c2pool::dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/merkle_root.hpp b/src/impl/dgb/coin/merkle_root.hpp index 0e3dd390a..e82f2426d 100644 --- a/src/impl/dgb/coin/merkle_root.hpp +++ b/src/impl/dgb/coin/merkle_root.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::build_block_merkle_root -- the block-body merkle-root SSOT. @@ -44,4 +45,4 @@ inline uint256 build_block_merkle_root(std::vector txids) } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/naughty_propagation.hpp b/src/impl/dgb/coin/naughty_propagation.hpp index 0392df147..150c6c09d 100644 --- a/src/impl/dgb/coin/naughty_propagation.hpp +++ b/src/impl/dgb/coin/naughty_propagation.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for DGB NAUGHTY-PROPAGATION ancestor punishment -- the pure-integer @@ -72,4 +73,4 @@ inline std::optional propagate_naughty_from_parent(std::uint32_t return naughty_child_generation(parent_naughty); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/node.hpp b/src/impl/dgb/coin/node.hpp index 1bfcca766..cbe34468f 100644 --- a/src/impl/dgb/coin/node.hpp +++ b/src/impl/dgb/coin/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -152,4 +153,4 @@ class Node : public dgb::interfaces::Node } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/node_interface.hpp b/src/impl/dgb/coin/node_interface.hpp index 186c1b37c..d15243058 100644 --- a/src/impl/dgb/coin/node_interface.hpp +++ b/src/impl/dgb/coin/node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -52,4 +53,4 @@ struct Node } // namespace interfaces -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/nonce_grinder.hpp b/src/impl/dgb/coin/nonce_grinder.hpp index fa597b4c4..7f01f245f 100644 --- a/src/impl/dgb/coin/nonce_grinder.hpp +++ b/src/impl/dgb/coin/nonce_grinder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::grind_won_nonce -- the embedded real work-gen nonce grinder @@ -96,4 +97,4 @@ grind_won_nonce(std::array& header, const u256& target, return std::nullopt; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/other_tx_assembler.hpp b/src/impl/dgb/coin/other_tx_assembler.hpp index 8eb2d7aae..24a072c8b 100644 --- a/src/impl/dgb/coin/other_tx_assembler.hpp +++ b/src/impl/dgb/coin/other_tx_assembler.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::assemble_other_txs -- the won-block reconstructor's (#82) bridge @@ -86,4 +87,4 @@ assemble_other_txs( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/other_tx_resolver.hpp b/src/impl/dgb/coin/other_tx_resolver.hpp index 31120b62c..01f711a7e 100644 --- a/src/impl/dgb/coin/other_tx_resolver.hpp +++ b/src/impl/dgb/coin/other_tx_resolver.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::resolve_other_tx_hashes -- the won-block reconstructor's (#82) @@ -99,4 +100,4 @@ resolve_other_tx_hashes( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/p2p_connection.cpp b/src/impl/dgb/coin/p2p_connection.cpp index 0fff8df5f..94dee3987 100644 --- a/src/impl/dgb/coin/p2p_connection.cpp +++ b/src/impl/dgb/coin/p2p_connection.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_connection.hpp" namespace dgb @@ -37,4 +38,4 @@ void Connection::get_header(uint256 id, BlockHeaderType response) } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/p2p_connection.hpp b/src/impl/dgb/coin/p2p_connection.hpp index d5ee8ef39..7675dea72 100644 --- a/src/impl/dgb/coin/p2p_connection.hpp +++ b/src/impl/dgb/coin/p2p_connection.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB coin-daemon P2P connection. 1:1 mirror of src/impl/btc/coin/p2p_connection.hpp. @@ -89,4 +90,4 @@ class Connection } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/p2p_messages.hpp b/src/impl/dgb/coin/p2p_messages.hpp index cdbc1a72d..2487a7e6f 100644 --- a/src/impl/dgb/coin/p2p_messages.hpp +++ b/src/impl/dgb/coin/p2p_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB coin-daemon P2P messages. 1:1 mirror of src/impl/btc/coin/p2p_messages.hpp diff --git a/src/impl/dgb/coin/p2p_node.cpp b/src/impl/dgb/coin/p2p_node.cpp index 8d20170b8..f925a3372 100644 --- a/src/impl/dgb/coin/p2p_node.cpp +++ b/src/impl/dgb/coin/p2p_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_node.hpp" namespace dgb diff --git a/src/impl/dgb/coin/p2p_node.hpp b/src/impl/dgb/coin/p2p_node.hpp index 9c24ef816..4f2f0da3a 100644 --- a/src/impl/dgb/coin/p2p_node.hpp +++ b/src/impl/dgb/coin/p2p_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB embedded P2P node. 1:1 mirror of src/impl/btc/coin/p2p_node.hpp (NON-MWEB). @@ -1031,4 +1032,4 @@ class NodeP2P : public core::ICommunicator, public core::INetwork, public core:: } // namespace node -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/pool_attempts_per_second.hpp b/src/impl/dgb/coin/pool_attempts_per_second.hpp index ec74fd824..25676d4e0 100644 --- a/src/impl/dgb/coin/pool_attempts_per_second.hpp +++ b/src/impl/dgb/coin/pool_attempts_per_second.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB POOL-ATTEMPTS-PER-SECOND estimator -- the pure arithmetic @@ -73,4 +74,4 @@ inline uint288 compute_pool_attempts_per_second(const PoolAttemptsInputs& in) { return in.attempts / uint288(time_span); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/pplns_payout_split.hpp b/src/impl/dgb/coin/pplns_payout_split.hpp index b2b75518f..cbf525a88 100644 --- a/src/impl/dgb/coin/pplns_payout_split.hpp +++ b/src/impl/dgb/coin/pplns_payout_split.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ============================================================================ // pplns_payout_split.hpp — SSOT: PPLNS weights -> consensus-sorted payout outputs. @@ -135,4 +136,4 @@ inline PplnsPayoutSplit compute_pplns_payout_split( return out; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/pplns_weight_walk.hpp b/src/impl/dgb/coin/pplns_weight_walk.hpp index 4c2c0d084..71b1dfe0d 100644 --- a/src/impl/dgb/coin/pplns_weight_walk.hpp +++ b/src/impl/dgb/coin/pplns_weight_walk.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ───────────────────────────────────────────────────────────────────────────── // SSOT: PPLNS weight walk — step 1 of generate_share_transaction(), lifted so the @@ -109,4 +110,4 @@ inline auto compute_pplns_weight_walk( return out; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/reconstruct_closure.hpp b/src/impl/dgb/coin/reconstruct_closure.hpp index cb1bdbe77..f6686b318 100644 --- a/src/impl/dgb/coin/reconstruct_closure.hpp +++ b/src/impl/dgb/coin/reconstruct_closure.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::make_reconstruct_closure -- the run-loop's faithful @@ -200,4 +201,4 @@ make_reconstruct_closure_from_template( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/reconstruct_won_block.hpp b/src/impl/dgb/coin/reconstruct_won_block.hpp index da4fcfd9b..d8b61fac8 100644 --- a/src/impl/dgb/coin/reconstruct_won_block.hpp +++ b/src/impl/dgb/coin/reconstruct_won_block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::reconstruct_won_block -- the won-block reconstructor's (#82) BODY: @@ -167,4 +168,4 @@ reconstruct_won_block_from_template( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/regrind_block.hpp b/src/impl/dgb/coin/regrind_block.hpp index f2e777e4d..ae2dfdf83 100644 --- a/src/impl/dgb/coin/regrind_block.hpp +++ b/src/impl/dgb/coin/regrind_block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::regrind_block_nonce -- the grind -> reconstruct -> submit @@ -90,4 +91,4 @@ regrind_block_nonce(std::vector& block_bytes, const u256& target, return out; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/rpc.cpp b/src/impl/dgb/coin/rpc.cpp index 8c9928468..615c51de6 100644 --- a/src/impl/dgb/coin/rpc.cpp +++ b/src/impl/dgb/coin/rpc.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "rpc.hpp" #include @@ -480,4 +481,4 @@ nlohmann::json NodeRPC::getblock(uint256 blockhash, int verbosity) } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/rpc.hpp b/src/impl/dgb/coin/rpc.hpp index 1d09a5ea5..5d50b94b4 100644 --- a/src/impl/dgb/coin/rpc.hpp +++ b/src/impl/dgb/coin/rpc.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -120,4 +121,4 @@ struct RPCAuthData } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/rpc_conf.hpp b/src/impl/dgb/coin/rpc_conf.hpp index 68cf346b3..e4e739c39 100644 --- a/src/impl/dgb/coin/rpc_conf.hpp +++ b/src/impl/dgb/coin/rpc_conf.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -95,4 +96,4 @@ inline void apply_endpoint_override(const std::string& hostport, RpcConf& out) } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/rpc_data.hpp b/src/impl/dgb/coin/rpc_data.hpp index 1589db1d2..8b52847df 100644 --- a/src/impl/dgb/coin/rpc_data.hpp +++ b/src/impl/dgb/coin/rpc_data.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -60,4 +61,4 @@ struct WorkData } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/rpc_request.hpp b/src/impl/dgb/coin/rpc_request.hpp index 1d5dc66d5..1bf165a08 100644 --- a/src/impl/dgb/coin/rpc_request.hpp +++ b/src/impl/dgb/coin/rpc_request.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -68,4 +69,4 @@ inline const char* dgb_genesis_hash(bool testnet) } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/scrypt_pow.hpp b/src/impl/dgb/coin/scrypt_pow.hpp index 6509769c3..3a1fcf088 100644 --- a/src/impl/dgb/coin/scrypt_pow.hpp +++ b/src/impl/dgb/coin/scrypt_pow.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // DGB-Scrypt proof-of-work digest CALL (M3 §7b / Stage 4b-4c work-gen). @@ -44,4 +45,4 @@ inline u256 scrypt_pow_hash(const std::array& header80) { return scrypt_pow_hash(header80.data()); } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/share_weight_decay.hpp b/src/impl/dgb/coin/share_weight_decay.hpp index 5a3941e12..e59d1684b 100644 --- a/src/impl/dgb/coin/share_weight_decay.hpp +++ b/src/impl/dgb/coin/share_weight_decay.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // V36 PPLNS exponential weight-decay parameters -- SSOT. // @@ -51,4 +52,4 @@ inline constexpr uint64_t decayed_attempts(uint64_t att, uint64_t decay_fp) { return (att * decay_fp) >> DECAY_PRECISION; } -} // namespace dgb::coin::weight_decay +} // namespace dgb::coin::weight_decay \ No newline at end of file diff --git a/src/impl/dgb/coin/softfork_check.hpp b/src/impl/dgb/coin/softfork_check.hpp index 07c462a09..d6aa34712 100644 --- a/src/impl/dgb/coin/softfork_check.hpp +++ b/src/impl/dgb/coin/softfork_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -110,4 +111,4 @@ inline std::set compute_required_softforks( return required; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/submit_classify.hpp b/src/impl/dgb/coin/submit_classify.hpp index 75cdd1556..3740af6a3 100644 --- a/src/impl/dgb/coin/submit_classify.hpp +++ b/src/impl/dgb/coin/submit_classify.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // submit_classify.hpp -- the Stage 4d mining_submit decision SSOT. @@ -61,4 +62,4 @@ inline SubmitClass classify_submission(const u256& pow_hash, return SubmitClass::Reject; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/tail_score_endpoints.hpp b/src/impl/dgb/coin/tail_score_endpoints.hpp index 88b72d54f..d1366dd00 100644 --- a/src/impl/dgb/coin/tail_score_endpoints.hpp +++ b/src/impl/dgb/coin/tail_score_endpoints.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB TAIL-HASHRATE-SCORE chain-walk endpoints -- the pure @@ -118,4 +119,4 @@ inline uint288 score_value(const uint288& total_work, int32_t time_span) return total_work / static_cast(time_span); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/template_builder.hpp b/src/impl/dgb/coin/template_builder.hpp index a6ffdccf0..e4f993972 100644 --- a/src/impl/dgb/coin/template_builder.hpp +++ b/src/impl/dgb/coin/template_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB block-template builder. Mirrors src/impl/btc/coin/template_builder.hpp. // Must emit p2pool-merged-v36-compatible templates (V36 master compat). @@ -161,4 +162,4 @@ inline nlohmann::json build_work_template(const WorkTemplateInputs& in) } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/template_capture.hpp b/src/impl/dgb/coin/template_capture.hpp index 9cc4c92d6..ca17b7132 100644 --- a/src/impl/dgb/coin/template_capture.hpp +++ b/src/impl/dgb/coin/template_capture.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // template_capture.hpp -- the per-job template-retention seam (#271): the // PRODUCTION captured_template_txs_fn provider that feeds the won-block @@ -132,4 +133,4 @@ class TemplateCapture }; } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/template_other_txs.hpp b/src/impl/dgb/coin/template_other_txs.hpp index affd088fb..a3b00d370 100644 --- a/src/impl/dgb/coin/template_other_txs.hpp +++ b/src/impl/dgb/coin/template_other_txs.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // template_other_txs.hpp -- the producer bridge between the embedded work // template's transactions[] (make_mempool_tx_source / embedded_tx_select.cpp) @@ -105,4 +106,4 @@ make_template_other_txs_fn( } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/transaction.cpp b/src/impl/dgb/coin/transaction.cpp index 7bd0c03cf..89f0f3f0f 100644 --- a/src/impl/dgb/coin/transaction.cpp +++ b/src/impl/dgb/coin/transaction.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "transaction.hpp" namespace dgb diff --git a/src/impl/dgb/coin/transaction.hpp b/src/impl/dgb/coin/transaction.hpp index ccee5b9bc..8adeded23 100644 --- a/src/impl/dgb/coin/transaction.hpp +++ b/src/impl/dgb/coin/transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB coin tx types. 1:1 mirror of src/impl/btc/coin/transaction.hpp @@ -221,4 +222,4 @@ void SerializeTransaction(const TxType& tx, StreamType& s, const TxParams& param } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/txidcache.hpp b/src/impl/dgb/coin/txidcache.hpp index ce4fbc489..b20cff150 100644 --- a/src/impl/dgb/coin/txidcache.hpp +++ b/src/impl/dgb/coin/txidcache.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB gbt-data -> txid cache. 1:1 mirror of src/impl/btc/coin/txidcache.hpp. @@ -85,4 +86,4 @@ class TXIDCache } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/witness_commitment.hpp b/src/impl/dgb/coin/witness_commitment.hpp index 8f7f012db..041258341 100644 --- a/src/impl/dgb/coin/witness_commitment.hpp +++ b/src/impl/dgb/coin/witness_commitment.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::add_witness_commitment -- the BIP141 coinbase witness-commitment @@ -139,4 +140,4 @@ inline void add_witness_commitment(MutableTransaction& coinbase, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/won_block_dispatch.hpp b/src/impl/dgb/coin/won_block_dispatch.hpp index 6443ea026..d0247ff44 100644 --- a/src/impl/dgb/coin/won_block_dispatch.hpp +++ b/src/impl/dgb/coin/won_block_dispatch.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::make_on_block_found -- the won-block DISPATCH handler the run-loop @@ -91,4 +92,4 @@ make_on_block_found(WonBlockReconstructor reconstruct, } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/won_block_finalize.hpp b/src/impl/dgb/coin/won_block_finalize.hpp index 29e493cbb..45c7e625f 100644 --- a/src/impl/dgb/coin/won_block_finalize.hpp +++ b/src/impl/dgb/coin/won_block_finalize.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::finalize_won_block_pow -- the grind->reconstruct->submit JOINT @@ -129,4 +130,4 @@ finalize_won_block_pow(std::vector block_bytes, const u256& targe return FinalizedWonBlock{std::move(block_bytes), std::move(hex), *out}; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/coin/won_share_inputs.hpp b/src/impl/dgb/coin/won_share_inputs.hpp index 64e4fe030..3979e251f 100644 --- a/src/impl/dgb/coin/won_share_inputs.hpp +++ b/src/impl/dgb/coin/won_share_inputs.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // dgb::coin::won_share_inputs -- the SHARE-SIDE half of the #82 faithful @@ -60,4 +61,4 @@ inline WonShareInputs won_share_inputs(const ShareT& share) } } // namespace coin -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/coin/work_ref_hash.hpp b/src/impl/dgb/coin/work_ref_hash.hpp index 61a2d5112..0911d0a04 100644 --- a/src/impl/dgb/coin/work_ref_hash.hpp +++ b/src/impl/dgb/coin/work_ref_hash.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ============================================================================ // work_ref_hash.hpp — prospective-work RefHashParams assembler (SSOT). @@ -192,4 +193,4 @@ inline RefHashParams make_work_ref_hash_params( return p; } -} // namespace dgb::coin +} // namespace dgb::coin \ No newline at end of file diff --git a/src/impl/dgb/config_coin.cpp b/src/impl/dgb/config_coin.cpp index d94b0e2fc..55e42120c 100644 --- a/src/impl/dgb/config_coin.cpp +++ b/src/impl/dgb/config_coin.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_coin.hpp" #include @@ -40,4 +41,4 @@ void CoinConfig::load() m_dev_relax_algo_softforks = node["dev_relax_algo_softforks"].as(); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/config_coin.hpp b/src/impl/dgb/config_coin.hpp index 725406cd9..22db57910 100644 --- a/src/impl/dgb/config_coin.hpp +++ b/src/impl/dgb/config_coin.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -211,4 +212,4 @@ class CoinConfig : protected core::Fileconfig bool m_dev_relax_algo_softforks{false}; }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/config_pool.cpp b/src/impl/dgb/config_pool.cpp index 728e2a632..1116ba33e 100644 --- a/src/impl/dgb/config_pool.cpp +++ b/src/impl/dgb/config_pool.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_pool.hpp" #include @@ -45,4 +46,4 @@ void PoolConfig::load() } } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/config_pool.hpp b/src/impl/dgb/config_pool.hpp index 5150d58bd..29b14f809 100644 --- a/src/impl/dgb/config_pool.hpp +++ b/src/impl/dgb/config_pool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -150,4 +151,4 @@ class PoolConfig : protected core::Fileconfig std::vector m_bootstrap_addrs; }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/conn_pplns_producer.hpp b/src/impl/dgb/conn_pplns_producer.hpp index b8d014059..31e272065 100644 --- a/src/impl/dgb/conn_pplns_producer.hpp +++ b/src/impl/dgb/conn_pplns_producer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // ============================================================================ // conn_pplns_producer.hpp — per-connection PPLNS-inputs producer-assembly SSOT. @@ -95,4 +96,4 @@ inline dgb::coin::ConnCoinbasePplnsInputs make_conn_pplns_inputs( return out; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/donation_consensus.hpp b/src/impl/dgb/donation_consensus.hpp index d1fbaf14a..12a272e26 100644 --- a/src/impl/dgb/donation_consensus.hpp +++ b/src/impl/dgb/donation_consensus.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // donation_consensus.hpp — Consensus-level donation script validation for DGB-Scrypt p2pool shares. @@ -129,4 +130,4 @@ build_expected_payouts(ShareTracker& tracker, return tracker.get_expected_payouts(best_share_hash, block_target, subsidy, donation_script); } -} // namespace dgb::consensus +} // namespace dgb::consensus \ No newline at end of file diff --git a/src/impl/dgb/download_stops.hpp b/src/impl/dgb/download_stops.hpp index 5ebd75458..0cb3aa289 100644 --- a/src/impl/dgb/download_stops.hpp +++ b/src/impl/dgb/download_stops.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the requester-side download stops-list — the bound that @@ -80,4 +81,4 @@ inline std::vector compute_download_stops( return stops; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/expected_time_to_block.hpp b/src/impl/dgb/expected_time_to_block.hpp index a917c6d40..70ac973c2 100644 --- a/src/impl/dgb/expected_time_to_block.hpp +++ b/src/impl/dgb/expected_time_to_block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB EXPECTED-TIME-TO-BLOCK diagnostic — the final pure-arithmetic @@ -65,4 +66,4 @@ inline double compute_expected_time_to_block(double average_attempts, return etb_secs; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/get_shares_walk.hpp b/src/impl/dgb/get_shares_walk.hpp index bd5506bb7..996551687 100644 --- a/src/impl/dgb/get_shares_walk.hpp +++ b/src/impl/dgb/get_shares_walk.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the pool share-exchange GetShares walk — the SHAREREQ -> SHAREREPLY @@ -106,4 +107,4 @@ std::vector collect_get_shares( return shares; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/messages.hpp b/src/impl/dgb/messages.hpp index edf78cb83..e817cfb56 100644 --- a/src/impl/dgb/messages.hpp +++ b/src/impl/dgb/messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // V36 DGB-Scrypt pool wire-message layer — namespace-only divergence from // src/impl/ltc/messages.hpp; message format byte-parity with p2pool-merged-v36. @@ -190,4 +191,4 @@ using Handler = MessageHandler< message_remember_tx >; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/node.cpp b/src/impl/dgb/node.cpp index 3636fc381..0325e7d2e 100644 --- a/src/impl/dgb/node.cpp +++ b/src/impl/dgb/node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include @@ -2397,4 +2398,4 @@ void NodeImpl::set_rss_limit_mb(long mb) g_rss_limit_mb = mb; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/node.hpp b/src/impl/dgb/node.hpp index d8aa896d9..3a6942992 100644 --- a/src/impl/dgb/node.hpp +++ b/src/impl/dgb/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "config_pool.hpp" @@ -684,4 +685,4 @@ class Actual : public pool::Protocol using Node = pool::NodeBridge; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/params.hpp b/src/impl/dgb/params.hpp index 74e1b645e..f2768e63e 100644 --- a/src/impl/dgb/params.hpp +++ b/src/impl/dgb/params.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // DGB CoinParams factory: builds a fully populated core::CoinParams for the @@ -128,4 +129,4 @@ inline core::CoinParams make_coin_params(bool testnet) return p; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/peer.hpp b/src/impl/dgb/peer.hpp index 91915040b..bf983a933 100644 --- a/src/impl/dgb/peer.hpp +++ b/src/impl/dgb/peer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/transaction.hpp" diff --git a/src/impl/dgb/pool_efficiency.hpp b/src/impl/dgb/pool_efficiency.hpp index bed04828c..7b1c8d06f 100644 --- a/src/impl/dgb/pool_efficiency.hpp +++ b/src/impl/dgb/pool_efficiency.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the DGB pool EFFICIENCY / REAL-HASHRATE diagnostics — the two pure @@ -57,4 +58,4 @@ inline double compute_real_pool_hashrate(double pool_hs, double stale_prop) { return pool_hs; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/pool_monitor.hpp b/src/impl/dgb/pool_monitor.hpp index 85c2aeb57..e7ffc005a 100644 --- a/src/impl/dgb/pool_monitor.hpp +++ b/src/impl/dgb/pool_monitor.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 3L (DGB port): Log-based pool monitoring for attack detection. @@ -373,4 +374,4 @@ class PoolMonitor } }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/protocol_actual.cpp b/src/impl/dgb/protocol_actual.cpp index 45fab872b..809a6787a 100644 --- a/src/impl/dgb/protocol_actual.cpp +++ b/src/impl/dgb/protocol_actual.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" @@ -271,4 +272,4 @@ void Actual::HANDLER(forget_tx) } } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/protocol_legacy.cpp b/src/impl/dgb/protocol_legacy.cpp index 92ba46749..8ea046c78 100644 --- a/src/impl/dgb/protocol_legacy.cpp +++ b/src/impl/dgb/protocol_legacy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" diff --git a/src/impl/dgb/redistribute.hpp b/src/impl/dgb/redistribute.hpp index cd0b42732..5d240fce8 100644 --- a/src/impl/dgb/redistribute.hpp +++ b/src/impl/dgb/redistribute.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Redistribute V2: advanced redistribution policy for shares from miners @@ -497,4 +498,4 @@ class Redistributor } }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/run_loop_mint.hpp b/src/impl/dgb/run_loop_mint.hpp index d102be8d2..09728c110 100644 --- a/src/impl/dgb/run_loop_mint.hpp +++ b/src/impl/dgb/run_loop_mint.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // run_loop_mint.hpp — DGB Phase B: worker->mint adapter SSOT. // @@ -110,4 +111,4 @@ inline uint256 mint_local_share_with_ratchet( static_cast(vote_version)); // desired_version (always target) } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/share.hpp b/src/impl/dgb/share.hpp index f25341100..a0336b436 100644 --- a/src/impl/dgb/share.hpp +++ b/src/impl/dgb/share.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/block.hpp" @@ -313,5 +314,4 @@ struct ShareChain : chain::ShareChain }; -} // namespace dgb - +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/share_check.hpp b/src/impl/dgb/share_check.hpp index 5f091a620..9af23b1a1 100644 --- a/src/impl/dgb/share_check.hpp +++ b/src/impl/dgb/share_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // P2: Share verification — check_hash_link, check_merkle_link, share init/check @@ -3160,4 +3161,4 @@ uint256 create_local_share( return share_hash; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/share_messages.hpp b/src/impl/dgb/share_messages.hpp index 7e2719dee..808963226 100644 --- a/src/impl/dgb/share_messages.hpp +++ b/src/impl/dgb/share_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // share_messages.hpp — V36 share-embedded messaging: decryption + validation // // Port of p2pool/share_messages.py (consensus-critical portions). @@ -578,4 +579,4 @@ inline std::vector create_message_data( return encrypt_message_envelope(inner, authority_pubkey); } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/share_tracker.hpp b/src/impl/dgb/share_tracker.hpp index 087d52c79..204a67c9d 100644 --- a/src/impl/dgb/share_tracker.hpp +++ b/src/impl/dgb/share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -2858,4 +2859,4 @@ class ShareTracker CumulativeWeights m_decayed_cache_result; }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/share_types.hpp b/src/impl/dgb/share_types.hpp index 41f8528e4..0ddae7665 100644 --- a/src/impl/dgb/share_types.hpp +++ b/src/impl/dgb/share_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -196,4 +197,4 @@ struct AbsworkV36Format } }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/stratum/work_source.cpp b/src/impl/dgb/stratum/work_source.cpp index 9f94dfa1e..d3a42d449 100644 --- a/src/impl/dgb/stratum/work_source.cpp +++ b/src/impl/dgb/stratum/work_source.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::stratum::DGBWorkSource — Stage 4a skeleton. // // All IWorkSource methods are stubbed to safe defaults. Subsequent @@ -670,4 +671,4 @@ uint256 DGBWorkSource::try_mint_share(const MintShareInputs& in) const return fn(in); } -} // namespace dgb::stratum +} // namespace dgb::stratum \ No newline at end of file diff --git a/src/impl/dgb/stratum/work_source.hpp b/src/impl/dgb/stratum/work_source.hpp index c73228ef3..73e0565fe 100644 --- a/src/impl/dgb/stratum/work_source.hpp +++ b/src/impl/dgb/stratum/work_source.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // dgb::stratum::DGBWorkSource — concrete `core::stratum::IWorkSource` @@ -302,4 +303,4 @@ class DGBWorkSource : public core::stratum::IWorkSource // ... cache fields land here in stage 4c }; -} // namespace dgb::stratum +} // namespace dgb::stratum \ No newline at end of file diff --git a/src/impl/dgb/test/algo_select_test.cpp b/src/impl/dgb/test/algo_select_test.cpp index 7e646a405..9e8340fd4 100644 --- a/src/impl/dgb/test/algo_select_test.cpp +++ b/src/impl/dgb/test/algo_select_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb M3 §7b multi-algo version classifier regression guard. // @@ -102,4 +103,4 @@ TEST(DgbAlgoSelect, AllKnownNonScryptAlgosAreContinuity) HeaderDisposition::ACCEPT_BY_CONTINUITY); EXPECT_EQ(dgb_header_disposition(PRIMARY | DGB_BLOCK_VERSION_ODO), HeaderDisposition::ACCEPT_BY_CONTINUITY); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/auto_ratchet_sim_test.cpp b/src/impl/dgb/test/auto_ratchet_sim_test.cpp index 5ebcc8d3e..c1db9aafd 100644 --- a/src/impl/dgb/test/auto_ratchet_sim_test.cpp +++ b/src/impl/dgb/test/auto_ratchet_sim_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb_auto_ratchet_sim_test: FENCED, additive rig-free SIM KAT that arms the // DGB G2 staged-migration harness // (scripts/dgb_g2_ratchet_staged_migration_harness.sh) C2/C3/C4/C5 rows WITHOUT @@ -350,4 +351,4 @@ TEST(DGB_AutoRatchetSim, C5_ContinuityVotesCannotOutrunScryptWorkGate) EXPECT_TRUE(w_t2 == uint288(1000)); EXPECT_TRUE(w_all2 == uint288(1000)); EXPECT_TRUE(inline_tail_ok(w_t2, w_all2)); // Scrypt work now 100% V36 -> gate passes -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/auto_ratchet_tail_guard_test.cpp b/src/impl/dgb/test/auto_ratchet_tail_guard_test.cpp index e4138af97..172029605 100644 --- a/src/impl/dgb/test/auto_ratchet_tail_guard_test.cpp +++ b/src/impl/dgb/test/auto_ratchet_tail_guard_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb_auto_ratchet_tail_guard_test: FENCED, additive conformance KAT for the // AutoRatchet WORK-WEIGHTED 60% tail guard SSOT (auto_ratchet_tail_guard.hpp). // @@ -144,4 +145,4 @@ TEST(AutoRatchetTailGuard, LargeWeightsAgreeWithInline) EXPECT_EQ(switched(target, total), inline_tail_ok(target, total)) << "pct=" << pct; } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_broadcast_path_election_test.cpp b/src/impl/dgb/test/aux_broadcast_path_election_test.cpp index 56cf52fe3..a9390ef98 100644 --- a/src/impl/dgb/test/aux_broadcast_path_election_test.cpp +++ b/src/impl/dgb/test/aux_broadcast_path_election_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE (phase DC) — broadcast-path single-fire proof KAT. // @@ -135,4 +136,4 @@ TEST(DGB_AuxBroadcastSingleFire, NoWinDoesNotBurnTheHash) { EXPECT_FALSE(ledger.already_fired(h)); // not recorded EXPECT_EQ(elect_and_claim(ledger, h, /*win*/true, true, true), AuxBroadcastPath::EmbeddedSubmitBlock); // genuine win still fires -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_bind_parsers_test.cpp b/src/impl/dgb/test/aux_doge_bind_parsers_test.cpp index 031cf9e20..1709885c3 100644 --- a/src/impl/dgb/test/aux_doge_bind_parsers_test.cpp +++ b/src/impl/dgb/test/aux_doge_bind_parsers_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (M3) — bind_aux_doge_parsers() PRODUCTION-binding KAT. // Fenced / test-only — links the PRODUCTION dgb object lib, consumes the shared @@ -249,4 +250,4 @@ TEST(DGB_AuxDogeBindParsers, BoundParserAuxRoundTripsByteIdentical) { EXPECT_EQ(tohex(reemit), tohex(whole)); } -#endif // AUX_DOGE +#endif // AUX_DOGE \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_db_commitment_bind_test.cpp b/src/impl/dgb/test/aux_doge_db_commitment_bind_test.cpp index e449f056c..851d3c4ed 100644 --- a/src/impl/dgb/test/aux_doge_db_commitment_bind_test.cpp +++ b/src/impl/dgb/test/aux_doge_db_commitment_bind_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DB) — DGB-as-PARENT AuxPoW commitment binding // KAT. Fenced / test-only — consumes the shared aux module, modifies nothing. @@ -193,4 +194,4 @@ TEST(DGB_AuxDogeDBCommitmentBind, CAuxPowDgbParentRoundTripStable) { doge::coin::CAuxPow rt; packed >> rt; EXPECT_EQ(pack_hex(rt), wire); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_dc_layout_verifier_test.cpp b/src/impl/dgb/test/aux_doge_dc_layout_verifier_test.cpp index f5c137c94..f9570c5f5 100644 --- a/src/impl/dgb/test/aux_doge_dc_layout_verifier_test.cpp +++ b/src/impl/dgb/test/aux_doge_dc_layout_verifier_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DC) — ASSEMBLED-BLOCK LAYOUT VERIFIER KAT. // Fenced (-DAUX_DOGE), test-only. Consumes the parent-neutral producer @@ -199,4 +200,4 @@ TEST(DGB_AuxDogeDCLayout, RelayIsUnconditionalPrimaryPath) { // DGB must ride the primary one. EXPECT_EQ(gated_path_relays(/*submit_ok=*/false), 0) << "gated path drops rejected-but-valid blocks (NOT DGB)"; EXPECT_EQ(gated_path_relays(/*submit_ok=*/true), 1); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_dc_proof_test.cpp b/src/impl/dgb/test/aux_doge_dc_proof_test.cpp index 68ac56628..0b575c628 100644 --- a/src/impl/dgb/test/aux_doge_dc_proof_test.cpp +++ b/src/impl/dgb/test/aux_doge_dc_proof_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DC) — DGB-as-PARENT AuxPoW PROOF byte-parity + // dual-target KAT. Fenced / test-only — consumes the shared aux module and the @@ -295,4 +296,4 @@ TEST(DGB_AuxDogeDCProof, RegtestH20RealDaemonDecodesThroughDgbBinding) { doge::coin::CAuxPow out_ltc; ::Unserialize(ps_ltc, out_ltc); EXPECT_EQ(pack_hex(out_dgb), pack_hex(out_ltc)); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_embed_livewire_test.cpp b/src/impl/dgb/test/aux_doge_embed_livewire_test.cpp index 86e9d7b7d..fb353ff38 100644 --- a/src/impl/dgb/test/aux_doge_embed_livewire_test.cpp +++ b/src/impl/dgb/test/aux_doge_embed_livewire_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DC) -- EMBED LIVE-WIRE KAT, -DAUX_DOGE=ON only. // Author-only; runs the instant the build host (.178/VM905) returns. Closes the @@ -244,4 +245,4 @@ TEST(DGB_AuxDogeEmbedLiveWire, SubmitConsumesExactlyTheParentSideProof) { EXPECT_EQ(seen_aux, runtime_proof); // same derivation, no parallel fixture EXPECT_EQ(doge.submit_calls, 1); // RPC-only submit fired once EXPECT_EQ(doge.last_hex, std::string("00") + runtime_proof); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_mm_commitment_test.cpp b/src/impl/dgb/test/aux_doge_mm_commitment_test.cpp index f6dc4b92a..75fabe84e 100644 --- a/src/impl/dgb/test/aux_doge_mm_commitment_test.cpp +++ b/src/impl/dgb/test/aux_doge_mm_commitment_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DB) — KAT for the DGB-side AuxPoW coinbase // merged-mining commitment builder. Fenced / test-only. @@ -160,4 +161,4 @@ TEST(DGB_AuxDogeMMCommitment, KAT_RealishRoot_MaxSize) { "efcdab89674523011032547698badcfe00ffeeddccbbaa998877665544332211" "ffffffff" "eeffc000"); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_doge_submit_test.cpp b/src/impl/dgb/test/aux_doge_submit_test.cpp index 1177d429c..5453552ff 100644 --- a/src/impl/dgb/test/aux_doge_submit_test.cpp +++ b/src/impl/dgb/test/aux_doge_submit_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (phase DC) -- SUBMIT-half KAT, -DAUX_DOGE=ON only. // Author-only companion to aux_doge_dc_proof_test (the proof/dual-target half). @@ -146,4 +147,4 @@ TEST(DGB_AuxDogeSubmit, DogeSubmitDoesNotTouchParentSeam) { handler(SHARE, AUXPOW); EXPECT_EQ(doge.submit_calls, 1); EXPECT_EQ(parent_digibyted.submit_calls, 0); // parent path untouched -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_dual_target_select_test.cpp b/src/impl/dgb/test/aux_dual_target_select_test.cpp index 23ef54608..0f4a89ffa 100644 --- a/src/impl/dgb/test/aux_dual_target_select_test.cpp +++ b/src/impl/dgb/test/aux_dual_target_select_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE (phase DC) — dual-target SELECTION scaffold KAT. // @@ -96,4 +97,4 @@ TEST(DGB_AuxDualTargetSelect, DogeWinRequiresMintedCommitment) { EXPECT_FALSE(selection_is_consistent( aux_mint_decision(false, true), dgb::coin::DualTargetFire{false, true})); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/aux_parent_coinbase_parity_test.cpp b/src/impl/dgb/test/aux_parent_coinbase_parity_test.cpp index b37a66928..0ffc636ee 100644 --- a/src/impl/dgb/test/aux_parent_coinbase_parity_test.cpp +++ b/src/impl/dgb/test/aux_parent_coinbase_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DGB+DOGE merged-mining (D0) — aux-pow parent-coinbase serialization PARITY // BASELINE KAT. Fenced / test-only — consumes the shared aux module, modifies @@ -185,4 +186,4 @@ TEST(DGB_AuxParentCoinbaseParity, MerkleTxRoundTripStable) { doge::coin::CMerkleTx<> rt; packed >> rt; EXPECT_EQ(pack_hex(rt), MERKLE_TX_WIRE); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/binomial_conf_interval_test.cpp b/src/impl/dgb/test/binomial_conf_interval_test.cpp index 70c9451b2..7ec4dc318 100644 --- a/src/impl/dgb/test/binomial_conf_interval_test.cpp +++ b/src/impl/dgb/test/binomial_conf_interval_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_binomial_conf_interval_test -- FENCED, additive KAT pinning the pure // arithmetic core of the p2pool util/math.py binomial_conf_interval (Wilson @@ -88,4 +89,4 @@ TEST(BinomialConfInterval, BracketsPointEstimateAndStaysInUnit) EXPECT_LE(r[1], 1.0); EXPECT_LE(r[0], r[1]); } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/block_assembly_test.cpp b/src/impl/dgb/test/block_assembly_test.cpp index 1c19fdc92..dcd66108e 100644 --- a/src/impl/dgb/test/block_assembly_test.cpp +++ b/src/impl/dgb/test/block_assembly_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb::coin::assemble_won_block / reconstruct_block_header test (#82 // broadcaster-gate, faithful as_block FRAMING half). @@ -332,4 +333,4 @@ TEST(DgbBlockAssembly, TxBearingRootMatchesBodyNotMerkleLink) EXPECT_NE(body_root, gtx_hash); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/block_broadcast_test.cpp b/src/impl/dgb/test/block_broadcast_test.cpp index 21ff7b4af..a253d9a8c 100644 --- a/src/impl/dgb/test/block_broadcast_test.cpp +++ b/src/impl/dgb/test/block_broadcast_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb::coin::broadcast_won_block dual-path dispatcher test (#82 broadcaster- // gate, dispatcher half). @@ -164,4 +165,4 @@ TEST(DgbBlockBroadcast, RpcThrowDoesNotMaskP2pWin) { EXPECT_TRUE(r.any()); EXPECT_STREQ(r.landed_first, "p2p"); EXPECT_EQ(seam.submit_calls, 1); // it was attempted (then threw) -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/chain_walk_window_test.cpp b/src/impl/dgb/test/chain_walk_window_test.cpp index 2cb37cd4b..f160527f6 100644 --- a/src/impl/dgb/test/chain_walk_window_test.cpp +++ b/src/impl/dgb/test/chain_walk_window_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb lookbehind chain-walk WINDOW clamp -- KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -84,4 +85,4 @@ TEST(DgbChainWalkWindow, DelegationMatchesPreDelegationInline) { << "actual=" << inline_actual; } } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/coin_node_seam_test.cpp b/src/impl/dgb/test/coin_node_seam_test.cpp index 9bd4b342b..9ecc2b6ae 100644 --- a/src/impl/dgb/test/coin_node_seam_test.cpp +++ b/src/impl/dgb/test/coin_node_seam_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb::coin::CoinNode seam-contract test (#82 broadcaster-gate, RPC-fallback // half). @@ -91,4 +92,4 @@ TEST(DgbCoinNodeSeam, SubmitNoRpcReturnsFalse) { dgb::coin::CoinNode bare(nullptr, nullptr); EXPECT_FALSE(bare.submit_block_hex("00", /*ignore_failure=*/false)); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/coinbase_value_parity_test.cpp b/src/impl/dgb/test/coinbase_value_parity_test.cpp index f26e7a64c..51aee99b3 100644 --- a/src/impl/dgb/test/coinbase_value_parity_test.cpp +++ b/src/impl/dgb/test/coinbase_value_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_coinbase_value_parity_test -- END-TO-END GBT-parity KAT for the embedded // coinbasevalue. @@ -221,4 +222,4 @@ TEST(DgbCoinbaseValueParity, EmptyMempoolEmitsPureSubsidy) EXPECT_EQ(t["coinbasevalue"].get(), dgb::CoinParams::subsidy(67200)); EXPECT_TRUE(t["transactions"].is_array()); EXPECT_TRUE(t["transactions"].empty()); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/compact_blocks_bip152_parity_test.cpp b/src/impl/dgb/test/compact_blocks_bip152_parity_test.cpp index 6e2ec2a0a..3f0f79518 100644 --- a/src/impl/dgb/test/compact_blocks_bip152_parity_test.cpp +++ b/src/impl/dgb/test/compact_blocks_bip152_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_compact_blocks_bip152_parity_test -- FENCED, additive KAT pinning the // BIP 152 compact-block RELAY wire primitives in coin/compact_blocks.hpp: @@ -161,4 +162,4 @@ TEST(DgbCompactBlocksBip152Parity, GetBlockTxnFirstAbsoluteAndEmpty) got.Unserialize(rs); EXPECT_TRUE(got.indexes.empty()); } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/conn_pplns_producer_test.cpp b/src/impl/dgb/test/conn_pplns_producer_test.cpp index 0ac00e747..505f35db3 100644 --- a/src/impl/dgb/test/conn_pplns_producer_test.cpp +++ b/src/impl/dgb/test/conn_pplns_producer_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB Phase B — per-connection PPLNS-inputs producer-assembly KAT. // // Locks dgb::make_conn_pplns_inputs() (conn_pplns_producer.hpp): the seam that @@ -159,4 +160,4 @@ TEST(ConnPplnsProducer, RoundTripEmbedsRefInOpReturn) { EXPECT_FALSE(parts.coinb1.empty()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/connection_coinbase_test.cpp b/src/impl/dgb/test/connection_coinbase_test.cpp index d0071fdb6..a567395f4 100644 --- a/src/impl/dgb/test/connection_coinbase_test.cpp +++ b/src/impl/dgb/test/connection_coinbase_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB Phase B — per-connection Stratum coinbase assembler + split KAT. // // Locks dgb::coin::build_connection_coinbase_parts() (coin/connection_coinbase.hpp) @@ -313,4 +314,4 @@ TEST(LastTxoutNonceSsot, DrawsAreDistinct) { EXPECT_EQ(seen.size(), static_cast(N)); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/desired_version_tally_test.cpp b/src/impl/dgb/test/desired_version_tally_test.cpp index 10e3254a2..6ca6209b1 100644 --- a/src/impl/dgb/test/desired_version_tally_test.cpp +++ b/src/impl/dgb/test/desired_version_tally_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb desired-version tally -- version->work / version->count accumulation KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -113,4 +114,4 @@ TEST(DgbDesiredVersionTally, FlatCountIgnoresWork) { auto c = dgb::accumulate_version_counts({36, 36, 36}); EXPECT_EQ(c[36], 3); // not 1008 -- work is ignored -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/dgb_pool_msg_wire_test.cpp b/src/impl/dgb/test/dgb_pool_msg_wire_test.cpp index 3e9defec4..6de35acd3 100644 --- a/src/impl/dgb/test/dgb_pool_msg_wire_test.cpp +++ b/src/impl/dgb/test/dgb_pool_msg_wire_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb pool wire-message layer — serialization conformance KAT. // // FENCED conformance test (no production code touched). src/impl/dgb/messages.hpp @@ -203,4 +204,4 @@ TEST(DgbPoolMsgWire, VersionDefaultRoundTrip) { EXPECT_EQ(m->m_best_share, u256("7f")); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/digishield_walk_test.cpp b/src/impl/dgb/test/digishield_walk_test.cpp index 1b060e176..cf038c7de 100644 --- a/src/impl/dgb/test/digishield_walk_test.cpp +++ b/src/impl/dgb/test/digishield_walk_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb M3 §7b DigiShield Scrypt-only ancestor-walk regression guard. // @@ -81,4 +82,4 @@ TEST(DigishieldWalk, ZeroWindowIsEmpty) { std::vector c(4, SCRYPT); EXPECT_TRUE(scrypt_window_ancestors(chain(c), c.size(), 0).empty()); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/download_stops_test.cpp b/src/impl/dgb/test/download_stops_test.cpp index 1e5b38490..c01bc1dc6 100644 --- a/src/impl/dgb/test/download_stops_test.cpp +++ b/src/impl/dgb/test/download_stops_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb download stops-list — requester-side SHAREREQ bound conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -223,4 +224,4 @@ TEST(DgbDownloadStops, DelegationMatchesPreDelegationInlineWalk) { // stop_set = {ha,hb,hc,hd, pa,pc} (pd NULL skipped); ascending by id: // pa(01) < pc(02) < ha(0a) < hb(0b) < hc(0c) < hd(0d). EXPECT_EQ(via_ssot, (std::vector{pa, pc, ha, hb, hc, hd})); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/embedded_coin_node_test.cpp b/src/impl/dgb/test/embedded_coin_node_test.cpp index de65445e1..db05fb235 100644 --- a/src/impl/dgb/test/embedded_coin_node_test.cpp +++ b/src/impl/dgb/test/embedded_coin_node_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_embedded_coin_node_test -- guards dgb::coin::EmbeddedCoinNode, the // SECOND caller of the build_work_template SSOT (the stratum DGBWorkSource is @@ -175,4 +176,4 @@ TEST(DgbEmbeddedCoinNode, EmptyTxSourceByteIdenticalToNoSource) EXPECT_EQ(build_work_template(empty_src.make_inputs(5)).dump(), build_work_template(no_src.make_inputs(5)).dump()); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/embedded_tx_select_test.cpp b/src/impl/dgb/test/embedded_tx_select_test.cpp index 1db51c252..587ccfd31 100644 --- a/src/impl/dgb/test/embedded_tx_select_test.cpp +++ b/src/impl/dgb/test/embedded_tx_select_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_embedded_tx_select_test -- pins make_mempool_tx_source (embedded_tx_select.cpp), // the production shaper that turns the embedded Mempool's fee-sorted selection @@ -288,4 +289,4 @@ TEST(DgbEmbeddedTxSelect, EndToEndTemplateAssemblyConformance) } // coinbasevalue carries the folded fee total verbatim (no double count). EXPECT_EQ(tmpl["coinbasevalue"].get(), subsidy + 1650ull); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/emergency_decay_saturation_test.cpp b/src/impl/dgb/test/emergency_decay_saturation_test.cpp index 442efbe2b..757b6649d 100644 --- a/src/impl/dgb/test/emergency_decay_saturation_test.cpp +++ b/src/impl/dgb/test/emergency_decay_saturation_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb emergency-decay (Step 3) saturating-shift regression guard. // @@ -227,4 +228,4 @@ TEST(EmergencyDecaySaturation, OldShapeDeathSpiralCasesExist) } } EXPECT_GT(total, 0) << "the wrap bug must be demonstrably reachable"; -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/expected_time_to_block_test.cpp b/src/impl/dgb/test/expected_time_to_block_test.cpp index b25eae17c..b4df149bd 100644 --- a/src/impl/dgb/test/expected_time_to_block_test.cpp +++ b/src/impl/dgb/test/expected_time_to_block_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::compute_expected_time_to_block — expected-time-to-block KAT. // // FENCED conformance test (no production code touched). Pins the @@ -92,4 +93,4 @@ TEST(DgbExpectedTimeToBlock, ChainRealHashrateThenEtbMatchesOracle) { dgb::compute_expected_time_to_block(avg, real_hs, false, true), oracle); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/forced_won_share_dualpath_test.cpp b/src/impl/dgb/test/forced_won_share_dualpath_test.cpp index d8996d7bc..4bd5b4b18 100644 --- a/src/impl/dgb/test/forced_won_share_dualpath_test.cpp +++ b/src/impl/dgb/test/forced_won_share_dualpath_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_forced_won_share_dualpath_test -- the #82 broadcaster-gate BINDING KAT. // @@ -255,4 +256,4 @@ TEST(DgbForcedWonShareDualPath, UnreconstructableForcedShareFiresNeitherArm) EXPECT_FALSE(did_relay); // P2P arm silent EXPECT_EQ(seam.submit_calls, 0); // submitblock fallback silent -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/g1_oracle_byte_parity_test.cpp b/src/impl/dgb/test/g1_oracle_byte_parity_test.cpp index 8d65ebbb2..1f63010cf 100644 --- a/src/impl/dgb/test/g1_oracle_byte_parity_test.cpp +++ b/src/impl/dgb/test/g1_oracle_byte_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // G1 greenlight-gate KAT — DGB net/consensus byte-parity vs the oracle. // // FENCED conformance test (no production code touched). This is the test-form @@ -121,4 +122,4 @@ TEST(G1OracleByteParity, DonationScriptVersionGate) { EXPECT_EQ(v36.back(), 0x87); // OP_EQUAL } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/genesis_check_test.cpp b/src/impl/dgb/test/genesis_check_test.cpp index 3b0a9f332..5947fad3f 100644 --- a/src/impl/dgb/test/genesis_check_test.cpp +++ b/src/impl/dgb/test/genesis_check_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb M3 chain-identity (genesis) regression guard. // @@ -70,4 +71,4 @@ TEST(DgbGenesis, SelectorPicksTestnet) TEST(DgbGenesis, SelectorBranchesDiffer) { EXPECT_STRNE(dgb_genesis_hash(true), dgb_genesis_hash(false)); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/gentx_coinbase_test.cpp b/src/impl/dgb/test/gentx_coinbase_test.cpp index e96b47caf..b22564bbb 100644 --- a/src/impl/dgb/test/gentx_coinbase_test.cpp +++ b/src/impl/dgb/test/gentx_coinbase_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB #82 — SSOT non-witness coinbase (gentx) assembler KAT. // // Locks dgb::coin::assemble_gentx_coinbase() (coin/gentx_coinbase.hpp) — the @@ -101,4 +102,4 @@ TEST(DGB_gentx_coinbase, SegwitPredicateIsTheOnlyDivergence) { EXPECT_NE(NOSEG_BYTES, SEG_BYTES); // both share the identical coinbase-script vin prefix and donation/op_return tail EXPECT_EQ(NOSEG_BYTES.substr(0, 90), SEG_BYTES.substr(0, 90)); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/gentx_share_path_test.cpp b/src/impl/dgb/test/gentx_share_path_test.cpp index e6cb9a0af..2d14506c1 100644 --- a/src/impl/dgb/test/gentx_share_path_test.cpp +++ b/src/impl/dgb/test/gentx_share_path_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB #82 / #172 — share-path gentx KAT. // // The helper-level KAT (gentx_coinbase_test) pins dgb::coin::assemble_gentx_coinbase @@ -419,4 +420,4 @@ TEST(DgbGentxSharePath, RefHashWorkPathSegwitFieldIsLoadBearing) << "segwit field not reaching the ref preimage -- placeholder regressed away"; } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/gentx_unpack_test.cpp b/src/impl/dgb/test/gentx_unpack_test.cpp index b1ed57470..b07c5fcbc 100644 --- a/src/impl/dgb/test/gentx_unpack_test.cpp +++ b/src/impl/dgb/test/gentx_unpack_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB #82 — gentx-bytes -> MutableTransaction unpack round-trip KAT. // // Locks dgb::coin::unpack_gentx_coinbase() (coin/gentx_unpack.hpp) — the @@ -150,4 +151,4 @@ TEST(DGB_gentx_unpack, TrailingBytesThrow) { auto bytes = unhex(NOSEG_BYTES); bytes.push_back(0x00); // one extra byte after a complete tx EXPECT_THROW(dgb::coin::unpack_gentx_coinbase(bytes), std::out_of_range); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/get_height_and_last_endpoints_test.cpp b/src/impl/dgb/test/get_height_and_last_endpoints_test.cpp index 6285d89c6..c6ca635f4 100644 --- a/src/impl/dgb/test/get_height_and_last_endpoints_test.cpp +++ b/src/impl/dgb/test/get_height_and_last_endpoints_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb get_height_and_last endpoints — chain-walk window arithmetic KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -111,4 +112,4 @@ TEST(DgbGhalEndpoints, WindowConsistencyNonCircular) { // active iff there is at least one share in range ASSERT_EQ(pplns_window_active(depth), expect_depth >= 1); } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/get_shares_walk_test.cpp b/src/impl/dgb/test/get_shares_walk_test.cpp index b1cc8b11f..59662b46f 100644 --- a/src/impl/dgb/test/get_shares_walk_test.cpp +++ b/src/impl/dgb/test/get_shares_walk_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb GetShares walk — share-exchange (SHAREREQ -> SHAREREPLY) conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -253,4 +254,4 @@ TEST(DgbGetSharesWalk, DelegationMatchesPreDelegationInlineWalk) { // absent -> skip; tip(5): walk 5,4,3,2 with 4 rejected -> [5,3,2]; // mid(2): walk 2,1,0 with 1=stop -> break after 2 -> [2]. EXPECT_EQ(ids(via_ssot), (std::vector{5, 3, 2, 2})); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/hash_format_parity_test.cpp b/src/impl/dgb/test/hash_format_parity_test.cpp index 8d8a44327..d63447d04 100644 --- a/src/impl/dgb/test/hash_format_parity_test.cpp +++ b/src/impl/dgb/test/hash_format_parity_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_hash_format_parity_test -- FENCED, additive KAT pinning the pure GBT // block-hash display formatter dgb::coin::u256_be_display_hex lifted into @@ -129,4 +130,4 @@ TEST(DgbHashFormatParity, FromLeBytesByteReversalIsBigEndianDisplay) "1716151413121110" "0f0e0d0c0b0a0908" "0706050403020100"); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/header_chain_test.cpp b/src/impl/dgb/test/header_chain_test.cpp index f58bb21d8..9d6b281d1 100644 --- a/src/impl/dgb/test/header_chain_test.cpp +++ b/src/impl/dgb/test/header_chain_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb M3 §7b HeaderChain Scrypt-only validate() + retarget-body guard. // @@ -783,5 +784,4 @@ TEST(HeaderChainTipHash, ContinuityHeaderHashIsTip) c1.block_hash = dgb::coin::u256::from_u64(0xbbbbull); ASSERT_EQ(hc.validate_and_append(c1), IngestResult::ACCEPTED_CONTINUITY); EXPECT_TRUE(hc.tip_hash().value() == dgb::coin::u256::from_u64(0xbbbbull)); -} - +} \ No newline at end of file diff --git a/src/impl/dgb/test/header_ingest_test.cpp b/src/impl/dgb/test/header_ingest_test.cpp index a5ec13cbb..543556f32 100644 --- a/src/impl/dgb/test/header_ingest_test.cpp +++ b/src/impl/dgb/test/header_ingest_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_header_ingest_test -- guards c2pool::dgb::wire_header_ingest, the // connector that feeds the embedded P2P header-download feed @@ -184,4 +185,4 @@ TEST(HeaderIngest, RejectedHeaderIsNotAppended) EXPECT_FALSE(chain.tip_height().has_value()); EXPECT_FALSE(chain.tip_hash().has_value()); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/header_sample_build_test.cpp b/src/impl/dgb/test/header_sample_build_test.cpp index db9bf5136..b8f1e9feb 100644 --- a/src/impl/dgb/test/header_sample_build_test.cpp +++ b/src/impl/dgb/test/header_sample_build_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // c2pool::dgb::make_header_sample / compact_to_target test (embedded-ingest // HeaderSample builder). @@ -135,4 +136,4 @@ TEST(MakeHeaderSample, NonScryptHeaderPowHashZero) EXPECT_TRUE(s.pow_hash.is_zero()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/mempool_ingest_test.cpp b/src/impl/dgb/test/mempool_ingest_test.cpp index 93f8c7454..cc1b0d255 100644 --- a/src/impl/dgb/test/mempool_ingest_test.cpp +++ b/src/impl/dgb/test/mempool_ingest_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_mempool_ingest_test -- pins c2pool::dgb::wire_mempool_ingest, the // connector that routes the embedded P2P `tx` relay (dgb::interfaces::Node:: @@ -122,4 +123,4 @@ TEST(MempoolIngest, UnwiredNodeIngestsNothing) node.new_tx.happened(Transaction(tagged_tx(0))); EXPECT_EQ(pool.size(), 0u); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/min_protocol_ratchet_test.cpp b/src/impl/dgb/test/min_protocol_ratchet_test.cpp index 117a21b1c..a518a29c8 100644 --- a/src/impl/dgb/test/min_protocol_ratchet_test.cpp +++ b/src/impl/dgb/test/min_protocol_ratchet_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb runtime P2P accept-floor RATCHET KAT. // // FENCED, additive (no production code touched -- pins the pure free function @@ -160,5 +161,4 @@ TEST(DgbMinProtocolRatchetWiring, AlreadyAtTargetShortCircuits) { EXPECT_EQ(dgb::apply_min_protocol_ratchet_decision(CL, CL, w, 36, TARGET, TARGET), TARGET); // even with a short chain the latch holds at target (never lowers). EXPECT_EQ(dgb::apply_min_protocol_ratchet_decision(0, CL, w, 36, TARGET, TARGET), TARGET); -} - +} \ No newline at end of file diff --git a/src/impl/dgb/test/naughty_propagation_test.cpp b/src/impl/dgb/test/naughty_propagation_test.cpp index 29f77e730..a152d4f12 100644 --- a/src/impl/dgb/test/naughty_propagation_test.cpp +++ b/src/impl/dgb/test/naughty_propagation_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb NAUGHTY-PROPAGATION ancestor-punishment KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -83,4 +84,4 @@ TEST(DgbNaughtyPropagation, EightGenerationChainMatchesOracleSequence) } EXPECT_EQ(gen, expected[i]) << "generation " << i; } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/nonce_grinder_test.cpp b/src/impl/dgb/test/nonce_grinder_test.cpp index a27edec4e..f27991403 100644 --- a/src/impl/dgb/test/nonce_grinder_test.cpp +++ b/src/impl/dgb/test/nonce_grinder_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB nonce grinder guard (coin/nonce_grinder.hpp) -- #82 Stage 4b/4c. // // Proves the embedded real work-gen primitive: grind_won_nonce increments the @@ -110,4 +111,4 @@ TEST(DgbNonceGrinderKAT, ReturnsNulloptWhenNoNonceInBudget) { EXPECT_FALSE(out.has_value()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/other_tx_assembler_test.cpp b/src/impl/dgb/test/other_tx_assembler_test.cpp index 7a32405bc..f463da946 100644 --- a/src/impl/dgb/test/other_tx_assembler_test.cpp +++ b/src/impl/dgb/test/other_tx_assembler_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_other_tx_assembler_test -- pins coin/other_tx_assembler.hpp, the won-block // reconstructor's (#82 sub-slice 2) bridge from the ordered other_tx hash list @@ -267,4 +268,4 @@ TEST(DgbOtherTxAssembler, WitnessOtherTxEmitsWitnessBlock) std::vector(4, 0xab)); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/other_tx_resolver_test.cpp b/src/impl/dgb/test/other_tx_resolver_test.cpp index 43f18a748..b1d10d640 100644 --- a/src/impl/dgb/test/other_tx_resolver_test.cpp +++ b/src/impl/dgb/test/other_tx_resolver_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_other_tx_resolver_test -- pins coin/other_tx_resolver.hpp, the won-block // reconstructor's (#82) transaction_hash_refs -> ordered other_tx hash walk. @@ -146,4 +147,4 @@ TEST(OtherTxResolver, WalkPastChainEndThrows) std::vector refs = { {3, 0} }; // only won<-p1<-p2 exist EXPECT_THROW(resolve_other_tx_hashes(a.won, refs, walk_of(a), nths_of(a)), std::out_of_range); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/pool_attempts_per_second_test.cpp b/src/impl/dgb/test/pool_attempts_per_second_test.cpp index c911d37ca..82a8e1ce2 100644 --- a/src/impl/dgb/test/pool_attempts_per_second_test.cpp +++ b/src/impl/dgb/test/pool_attempts_per_second_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::compute_pool_attempts_per_second -- pool attempts/second KAT. // // FENCED conformance test (no production code touched). Pins the pure arithmetic @@ -104,4 +105,4 @@ TEST(DgbPoolAttempts, WideAttemptsNoOverflow) { EXPECT_EQ(compute_pool_attempts_per_second(window(2, big, 12, 10)), half); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/pool_efficiency_test.cpp b/src/impl/dgb/test/pool_efficiency_test.cpp index f9fb6bb74..9a3d3d559 100644 --- a/src/impl/dgb/test/pool_efficiency_test.cpp +++ b/src/impl/dgb/test/pool_efficiency_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::compute_stale_prop / compute_real_pool_hashrate — pool efficiency KAT. // // FENCED conformance test (no production code touched). Pins the pool @@ -85,4 +86,4 @@ TEST(DgbPoolEfficiency, ChainStalePropThenRealHashrateMatchesOracle) { EXPECT_DOUBLE_EQ(dgb::compute_real_pool_hashrate(pool_hs, sp), oracle); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/pplns_payout_split_test.cpp b/src/impl/dgb/test/pplns_payout_split_test.cpp index 74a69d45e..0a8c9ca0e 100644 --- a/src/impl/dgb/test/pplns_payout_split_test.cpp +++ b/src/impl/dgb/test/pplns_payout_split_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB Phase B — PPLNS weights -> consensus-sorted payout outputs KAT. // // Locks dgb::coin::compute_pplns_payout_split() (coin/pplns_payout_split.hpp) @@ -256,4 +257,4 @@ TEST(PplnsPayoutSplitInvariance, HelperEqualsLegacyInlineBattery) } } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/reconstruct_closure_test.cpp b/src/impl/dgb/test/reconstruct_closure_test.cpp index 1f41b2643..92a82fd6f 100644 --- a/src/impl/dgb/test/reconstruct_closure_test.cpp +++ b/src/impl/dgb/test/reconstruct_closure_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_reconstruct_closure_test -- pins coin/reconstruct_closure.hpp, the run- // loop's faithful WonBlockReconstructor (#82) that main_dgb.cpp binds into @@ -395,4 +396,4 @@ TEST(DgbReconstructClosure, FromTemplateOtherTxsThrowFailsClosed) throw std::runtime_error("template boom"); }); EXPECT_FALSE(closure(won).has_value()); // broad catch, not just out_of_range -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/reconstruct_won_block_test.cpp b/src/impl/dgb/test/reconstruct_won_block_test.cpp index 6a4347e59..bc9833b31 100644 --- a/src/impl/dgb/test/reconstruct_won_block_test.cpp +++ b/src/impl/dgb/test/reconstruct_won_block_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_reconstruct_won_block_test -- pins coin/reconstruct_won_block.hpp, the // won-block reconstructor's (#82) BODY: the single composition the dispatch @@ -401,5 +402,4 @@ TEST(DgbReconstructWonBlock, WonShareInputsDrivesTemplateReconstructIdentically) ASSERT_EQ(blk.m_txs.size(), 3u); // gentx + 2 template txs EXPECT_EQ(blk.m_txs[0].vin[0].prevout.index, 0xffffffffu); } -} // namespace - +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/redistribute_delegate_ghal_test.cpp b/src/impl/dgb/test/redistribute_delegate_ghal_test.cpp index 9dea81c68..9109be45e 100644 --- a/src/impl/dgb/test/redistribute_delegate_ghal_test.cpp +++ b/src/impl/dgb/test/redistribute_delegate_ghal_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb redistribute -> get_height_and_last SSOT byte-identity DELEGATION KAT. // // FENCED, additive. Pins the runtime rewire of redistribute.hpp:454-455 @@ -72,4 +73,4 @@ TEST(DgbRedistributeDelegateGhal, ActivationBoundaryAbsolute) { EXPECT_FALSE(!pplns_window_active(pplns_window_depth(CL_MAIN, CL_MAIN))); // clamped, active EXPECT_TRUE (!pplns_window_active(pplns_window_depth(-3, CL_MAIN))); // negative -> inactive EXPECT_EQ(pplns_window_depth(CL_MAIN + 50, CL_MAIN), CL_MAIN); // clamp to RCL -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/redistribute_test.cpp b/src/impl/dgb/test/redistribute_test.cpp index c1e1479bc..249ea639b 100644 --- a/src/impl/dgb/test/redistribute_test.cpp +++ b/src/impl/dgb/test/redistribute_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB Scrypt-only coin module — Redistribute V2 conformance fixtures (Phase B). // Mirrors src/impl/dgb/redistribute.hpp, ported byte-for-byte from // src/impl/ltc/redistribute.hpp (namespace flip only). Pins the deterministic @@ -196,4 +197,4 @@ TEST(DgbRedistribute, FeeWithoutOperatorIdentityIsFailSafeNull) EXPECT_TRUE(res.pubkey_hash.IsNull()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/regrind_block_test.cpp b/src/impl/dgb/test/regrind_block_test.cpp index 8fdf65b78..db83098d9 100644 --- a/src/impl/dgb/test/regrind_block_test.cpp +++ b/src/impl/dgb/test/regrind_block_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_regrind_block_test -- the grind -> reconstruct -> submit INTEGRATION // seam guard (coin/regrind_block.hpp), #82 Stage 4b/4c. @@ -136,4 +137,4 @@ TEST(DgbRegrindBlockKAT, Deterministic) { EXPECT_EQ(a, b); // identical re-ground blobs } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/rpc_request_test.cpp b/src/impl/dgb/test/rpc_request_test.cpp index eb008ba06..d3dd58f6a 100644 --- a/src/impl/dgb/test/rpc_request_test.cpp +++ b/src/impl/dgb/test/rpc_request_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb M3 RPC request-shape regression guard. // @@ -81,4 +82,4 @@ TEST(DgbRpcRequest, GbtPreservesCallerRulesAndForcesScrypt) EXPECT_EQ(j["rules"][0].get(), "segwit"); EXPECT_EQ(j["rules"][1].get(), "!extra"); EXPECT_EQ(j["algo"].get(), "scrypt"); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/scrypt_pow_test.cpp b/src/impl/dgb/test/scrypt_pow_test.cpp index f9af6edaa..c43e31fb5 100644 --- a/src/impl/dgb/test/scrypt_pow_test.cpp +++ b/src/impl/dgb/test/scrypt_pow_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB-Scrypt PoW digest CALL guard (coin/scrypt_pow.hpp) -- Stage 4b/4c. // // Pins (1) the scrypt_1024_1_1_256 digest bytes over a fixed 80-byte header and @@ -78,4 +79,4 @@ TEST(DgbScryptPowKAT, SatisfiesEqualTarget) { EXPECT_FALSE(pow > expected_pow()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/share_bits_oracle_pin_test.cpp b/src/impl/dgb/test/share_bits_oracle_pin_test.cpp index 745720cb9..3e9e83590 100644 --- a/src/impl/dgb/test/share_bits_oracle_pin_test.cpp +++ b/src/impl/dgb/test/share_bits_oracle_pin_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb sharechain `bits` (compact FloatingInteger) encoding — oracle-LITERAL pin. // // FENCED conformance KAT (Phase B, pool/share layer; no production code touched). @@ -117,4 +118,4 @@ TEST(DgbShareBitsOraclePin, GenesisDesiredInRangeEncodesToOracleMaxOver2) { EXPECT_EQ(st.bits, ORACLE_BITS_MAX_OVER_2); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/share_target_genesis_test.cpp b/src/impl/dgb/test/share_target_genesis_test.cpp index f8d16d1b6..c9727fe79 100644 --- a/src/impl/dgb/test/share_target_genesis_test.cpp +++ b/src/impl/dgb/test/share_target_genesis_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::ShareTracker::compute_share_target — genesis/unknown-prev branch KAT. // // FENCED conformance test (no production code touched). Pins the share-target @@ -74,4 +75,4 @@ TEST(DgbShareTargetGenesis, DesiredInRangePreserved) { EXPECT_TRUE(!(tgt < (MAX_TARGET / 30))); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/share_target_retarget_test.cpp b/src/impl/dgb/test/share_target_retarget_test.cpp index 9086df9fd..eec6ed3d9 100644 --- a/src/impl/dgb/test/share_target_retarget_test.cpp +++ b/src/impl/dgb/test/share_target_retarget_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::ShareTracker::compute_share_target — NON-genesis (seeded sharechain) // branch KAT: Step-3 emergency time-based decay + Step-4 ±10% clamp. // @@ -186,4 +187,4 @@ TEST(DgbShareTargetRetarget, C5_LoClamp) { expect_deep_branch_distinct(st.max_bits); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/share_test.cpp b/src/impl/dgb/test/share_test.cpp index c16937e63..7e5a46bf7 100644 --- a/src/impl/dgb/test/share_test.cpp +++ b/src/impl/dgb/test/share_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB Scrypt-only coin module — share / consensus-identity fixtures (M3). // Mirrors src/impl/btc/test + src/impl/ltc/test. Locks the oracle-conformed // consensus + sharechain-identity params against frstrtr/p2pool-dgb-scrypt @@ -1142,4 +1143,4 @@ TEST(WorkRefHashAssembler, PayoutIdentityClassification) { EXPECT_EQ(std::memcmp(p2wpkh.pubkey_hash.data(), WRH_P2WPKH.data() + 2, 20), 0); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/share_weight_decay_test.cpp b/src/impl/dgb/test/share_weight_decay_test.cpp index ad299d425..21e780d24 100644 --- a/src/impl/dgb/test/share_weight_decay_test.cpp +++ b/src/impl/dgb/test/share_weight_decay_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::coin::weight_decay -- V36 PPLNS exponential weight-decay KAT. // // FENCED conformance test (no production code touched). Pins the decay-rate @@ -247,4 +248,4 @@ TEST(DgbWeightDecay, DecayedCumulativeWalkVisibleDecayTinyHalfLife) { EXPECT_EQ(r.decayed, (std::vector{1000, 653, 426, 278})); EXPECT_EQ(r.cumulative, (std::vector{1000, 1653, 2079, 2357})); EXPECT_EQ(r.total, uint64_t(2357)); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/softfork_check_test.cpp b/src/impl/dgb/test/softfork_check_test.cpp index ed9bb548d..5af127fab 100644 --- a/src/impl/dgb/test/softfork_check_test.cpp +++ b/src/impl/dgb/test/softfork_check_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb M3 softfork-detection regression guard. // @@ -259,4 +260,4 @@ TEST(DgbRequiredSoftforks, UnknownChainFollowsFlag) // — relaxed only when the explicit flag is set. EXPECT_EQ(compute_required_softforks(kBaseRequired, "", false), kBaseRequired); EXPECT_EQ(compute_required_softforks(kBaseRequired, "", true), kRelaxed); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/submit_classify_test.cpp b/src/impl/dgb/test/submit_classify_test.cpp index 54115c5f7..0dbd1685a 100644 --- a/src/impl/dgb/test/submit_classify_test.cpp +++ b/src/impl/dgb/test/submit_classify_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // submit_classify_test.cpp -- KAT for the Stage 4d mining_submit decision SSOT // (coin/submit_classify.hpp). Pins the three-way ladder + BOTH inclusive @@ -75,4 +76,4 @@ TEST(DgbSubmitClassify, InvertedTargetsNeverSpuriousWonBlock) { // pow just above the real block magnitude (1000): not a block. EXPECT_NE(classify_submission(u256::from_u64(1500), loose, tight), SubmitClass::WonBlock); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/tail_score_endpoints_test.cpp b/src/impl/dgb/test/tail_score_endpoints_test.cpp index 8fa9d18e5..186dee4be 100644 --- a/src/impl/dgb/test/tail_score_endpoints_test.cpp +++ b/src/impl/dgb/test/tail_score_endpoints_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb tail-hashrate-score endpoints — chain-walk endpoint arithmetic KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -103,4 +104,4 @@ TEST(DgbTailScoreEndpoints, CompositeUnresolvableScoreHandDerived) { EXPECT_EQ(span, 1000000); EXPECT_EQ(time_span, 75000000); EXPECT_EQ(score, uint288(10)); // tiny but non-zero, hand-computed -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/template_builder_test.cpp b/src/impl/dgb/test/template_builder_test.cpp index 7fa94f848..3a9ee65e7 100644 --- a/src/impl/dgb/test/template_builder_test.cpp +++ b/src/impl/dgb/test/template_builder_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb_template_builder_test — guards the dgb::coin::build_work_template SSOT // (Stage 4c extraction). The work-template assembly was lifted out of // DGBWorkSource::get_current_work_template() into coin/template_builder.hpp so @@ -146,4 +147,4 @@ TEST(DgbTemplateBuilder, DeterministicForIdenticalInputs) { EXPECT_EQ(build_work_template(make_inputs()).dump(), build_work_template(make_inputs()).dump()); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/template_capture_test.cpp b/src/impl/dgb/test/template_capture_test.cpp index 28dafb786..020ed3059 100644 --- a/src/impl/dgb/test/template_capture_test.cpp +++ b/src/impl/dgb/test/template_capture_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_template_capture_test -- pins coin/template_capture.hpp, the per-job // template-retention seam (#271): the PRODUCTION captured_template_txs_fn the @@ -169,4 +170,4 @@ TEST(DgbTemplateCapture, BoundedFifoEvictsOldest) EXPECT_TRUE(cap.provide(hash_for(H_A)).empty()); // oldest evicted -> miss EXPECT_EQ(cap.provide(hash_for(H_B)).size(), 2u); // newest retained EXPECT_EQ(cap.provide(hash_for(H_C)).size(), 2u); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/template_other_txs_test.cpp b/src/impl/dgb/test/template_other_txs_test.cpp index 9ae96d3c3..9ab8a367d 100644 --- a/src/impl/dgb/test/template_other_txs_test.cpp +++ b/src/impl/dgb/test/template_other_txs_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb_template_other_txs_test -- pins coin/template_other_txs.hpp, the producer // bridge that decodes the embedded work template's transactions[] (the GBT data @@ -229,4 +230,4 @@ TEST(DgbTemplateOtherTxs, BadProviderFailsClosed) make_template_other_txs_fn([bad](const uint256&) { return bad; })); EXPECT_FALSE(closure(won).has_value()); // decode throw -> nullopt, no broadcast -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/think_p1_desired_emit_test.cpp b/src/impl/dgb/test/think_p1_desired_emit_test.cpp index 8fcc08d8f..d260bca71 100644 --- a/src/impl/dgb/test/think_p1_desired_emit_test.cpp +++ b/src/impl/dgb/test/think_p1_desired_emit_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb think() Phase-1 DESIRED-EMIT decision conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -120,4 +121,4 @@ TEST(ThinkP1DesiredEmit, DelegationMatchesPreDelegationInlineLadder) } } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/think_p1_walk_bounds_test.cpp b/src/impl/dgb/test/think_p1_walk_bounds_test.cpp index 9109d204d..477fd45d2 100644 --- a/src/impl/dgb/test/think_p1_walk_bounds_test.cpp +++ b/src/impl/dgb/test/think_p1_walk_bounds_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb think() Phase-1 desired-set walk BOUNDS conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -112,4 +113,4 @@ TEST(ThinkP1WalkBounds, DelegationMatchesPreDelegationInlineWalk) } } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/think_p2_walk_bounds_test.cpp b/src/impl/dgb/test/think_p2_walk_bounds_test.cpp index a2a34432b..112532817 100644 --- a/src/impl/dgb/test/think_p2_walk_bounds_test.cpp +++ b/src/impl/dgb/test/think_p2_walk_bounds_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb think() Phase-2 verification-extension walk BOUNDS conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -92,4 +93,4 @@ TEST(ThinkP2WalkBounds, GetIsMinOfWantAndCan) } } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/think_p3_best_head_test.cpp b/src/impl/dgb/test/think_p3_best_head_test.cpp index 17da1af0c..efba21b6c 100644 --- a/src/impl/dgb/test/think_p3_best_head_test.cpp +++ b/src/impl/dgb/test/think_p3_best_head_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // FENCED, additive KAT pinning the think() Phase-3 per-tail best-head // selection in think_p3_best_head.hpp vs the p2pool data.py think() oracle // (max(verified.tails[t], key=verified.get_work), first-max tiebreak). @@ -94,4 +95,4 @@ TEST(ThinkP3BestHead, MatchesIndependentReferenceScan) { EXPECT_TRUE(r.found); EXPECT_EQ(r.head, best_head); // = 4 (first 70-work head, 6:40 superseded) EXPECT_EQ(r.work, best_work); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/think_p4_head_keys_test.cpp b/src/impl/dgb/test/think_p4_head_keys_test.cpp index 369ab22c6..f53a62389 100644 --- a/src/impl/dgb/test/think_p4_head_keys_test.cpp +++ b/src/impl/dgb/test/think_p4_head_keys_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // KAT pinning the think() Phase-4 head-score key construction // (think_p4_head_keys.hpp) against the p2pool data.py think() Phase-4 oracle: // selection key (adjusted_work, -reason, -time_seen) with a one-share punishment @@ -102,4 +103,4 @@ TEST(ThinkP4HeadKeys, DelegationMatchesPreDelegationInlineArithmetic) { EXPECT_EQ(ssot.neg_reason, ref.neg_reason); EXPECT_EQ(ssot.neg_time_seen, ref.neg_ts); } -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/think_p5_best_share_punish_test.cpp b/src/impl/dgb/test/think_p5_best_share_punish_test.cpp index c4b8a8695..135f211b4 100644 --- a/src/impl/dgb/test/think_p5_best_share_punish_test.cpp +++ b/src/impl/dgb/test/think_p5_best_share_punish_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb think() Phase-5 BEST-SHARE PUNISH WALK conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -131,4 +132,4 @@ TEST(ThinkP5BestSharePunish, NaughtyWithNullPrevReportsPunish) EXPECT_EQ(r.punish_val, 2); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/think_p6_desired_cutoff_test.cpp b/src/impl/dgb/test/think_p6_desired_cutoff_test.cpp index 948389210..f2927a704 100644 --- a/src/impl/dgb/test/think_p6_desired_cutoff_test.cpp +++ b/src/impl/dgb/test/think_p6_desired_cutoff_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb think() Phase-6 desired-shares TIMESTAMP CUTOFF conformance KAT. // // FENCED, additive (no production code touched this slice). Pins @@ -133,4 +134,4 @@ TEST(ThinkP6DesiredCutoff, DelegationMatchesPreDelegationInlineKeep) } } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/witness_commitment_test.cpp b/src/impl/dgb/test/witness_commitment_test.cpp index 900f541b2..87b194603 100644 --- a/src/impl/dgb/test/witness_commitment_test.cpp +++ b/src/impl/dgb/test/witness_commitment_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb::coin::add_witness_commitment / assemble_won_block witness-commitment KAT // (#82 broadcaster-gate, POPULATED-block witness slice, 2026-06-25). @@ -242,4 +243,4 @@ TEST(DgbWitnessCommitment, AssembleInjectsForWitnessBodyOnly) } } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/won_block_dispatch_test.cpp b/src/impl/dgb/test/won_block_dispatch_test.cpp index cdbf8a7d4..32fe034e7 100644 --- a/src/impl/dgb/test/won_block_dispatch_test.cpp +++ b/src/impl/dgb/test/won_block_dispatch_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // dgb::coin::make_on_block_found won-block dispatch wiring test (#82 // broadcaster-gate, dispatch half). @@ -137,4 +138,4 @@ TEST(DgbWonBlockDispatch, MissingReconstructorIsSafeNoOp) { auto handler = dgb::coin::make_on_block_found( /*reconstruct=*/{}, /*p2p_relay=*/{}, /*seam=*/nullptr); EXPECT_NO_THROW(handler(hash_a())); -} +} \ No newline at end of file diff --git a/src/impl/dgb/test/won_block_finalize_test.cpp b/src/impl/dgb/test/won_block_finalize_test.cpp index 3dd59f16d..c38130db5 100644 --- a/src/impl/dgb/test/won_block_finalize_test.cpp +++ b/src/impl/dgb/test/won_block_finalize_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DGB won-block finalize joint (coin/won_block_finalize.hpp) -- #82 gate. // // Pins finalize_won_block_pow: the grind->reconstruct->submit composition that @@ -121,4 +122,4 @@ TEST(DgbWonBlockFinalizeKAT, FailsClosedOnShortInput) { EXPECT_FALSE(out.has_value()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/test/work_source_test.cpp b/src/impl/dgb/test/work_source_test.cpp index 9c5e1e42e..4041b7806 100644 --- a/src/impl/dgb/test/work_source_test.cpp +++ b/src/impl/dgb/test/work_source_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // dgb::stratum::DGBWorkSource — Stage 4a skeleton construction + contract test. // // Proves the work source instantiates against the live coin types @@ -630,4 +631,4 @@ TEST(DgbWorkSource, ConnectionCoinbaseProducerNulloptYieldsEmptyJob) EXPECT_TRUE(r.coinb2.empty()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/dgb/think_p1_desired_emit.hpp b/src/impl/dgb/think_p1_desired_emit.hpp index b321b2cdd..68460f4af 100644 --- a/src/impl/dgb/think_p1_desired_emit.hpp +++ b/src/impl/dgb/think_p1_desired_emit.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-1 DESIRED-EMIT decision — the requester-side rule @@ -75,4 +76,4 @@ inline ThinkP1DesiredEmit think_p1_desired_emit(bool last_is_null, return ThinkP1DesiredEmit::EmitRequest; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/think_p1_walk_bounds.hpp b/src/impl/dgb/think_p1_walk_bounds.hpp index e493bf2e3..e245969ec 100644 --- a/src/impl/dgb/think_p1_walk_bounds.hpp +++ b/src/impl/dgb/think_p1_walk_bounds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-1 desired-set walk BOUNDS — the two pure integer @@ -54,4 +55,4 @@ inline bool think_p1_in_pruning_zone(int32_t head_height, int32_t chain_length) return head_height >= 2 * chain_length + 10; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/think_p2_walk_bounds.hpp b/src/impl/dgb/think_p2_walk_bounds.hpp index 47e74489f..a036d1eff 100644 --- a/src/impl/dgb/think_p2_walk_bounds.hpp +++ b/src/impl/dgb/think_p2_walk_bounds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-2 verification-extension walk BOUNDS — the three @@ -64,4 +65,4 @@ inline ThinkP2WalkBounds think_p2_walk_bounds(int32_t head_height, return {want, can, get}; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/think_p3_best_head.hpp b/src/impl/dgb/think_p3_best_head.hpp index 706580fcb..53b10c371 100644 --- a/src/impl/dgb/think_p3_best_head.hpp +++ b/src/impl/dgb/think_p3_best_head.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-3 per-tail BEST-HEAD selection — the inner @@ -69,4 +70,4 @@ auto think_p3_best_head_by_work(const HashRange& head_hashes, return r; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/think_p4_head_keys.hpp b/src/impl/dgb/think_p4_head_keys.hpp index 3d92e2d13..89c3daf8e 100644 --- a/src/impl/dgb/think_p4_head_keys.hpp +++ b/src/impl/dgb/think_p4_head_keys.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-4 HEAD-SCORE KEY construction — the per-head sort @@ -80,4 +81,4 @@ ThinkP4HeadKeys think_p4_head_score_keys(Work work_score, }; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/think_p5_best_share_punish.hpp b/src/impl/dgb/think_p5_best_share_punish.hpp index 4e7dc0dc3..12e56e47f 100644 --- a/src/impl/dgb/think_p5_best_share_punish.hpp +++ b/src/impl/dgb/think_p5_best_share_punish.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-5 BEST-SHARE PUNISH WALK — the pure graph decision @@ -112,4 +113,4 @@ inline P5Result think_p5_best_share_punish( return {best, punish_val}; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/think_p6_desired_cutoff.hpp b/src/impl/dgb/think_p6_desired_cutoff.hpp index cdd202935..29639c5e5 100644 --- a/src/impl/dgb/think_p6_desired_cutoff.hpp +++ b/src/impl/dgb/think_p6_desired_cutoff.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // SSOT for the think() Phase-6 desired-shares TIMESTAMP CUTOFF — the two pure @@ -58,4 +59,4 @@ inline bool think_p6_passes_cutoff(uint32_t max_timestamp, uint32_t cutoff) return max_timestamp >= cutoff; } -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/dgb/whale_departure.hpp b/src/impl/dgb/whale_departure.hpp index d590de978..a3ac1874c 100644 --- a/src/impl/dgb/whale_departure.hpp +++ b/src/impl/dgb/whale_departure.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 1c: Whale departure recovery — non-consensus local heuristic. @@ -191,4 +192,4 @@ class WhaleDepartureDetector uint32_t gap_trigger_periods_ = 8; // share gap trigger }; -} // namespace dgb +} // namespace dgb \ No newline at end of file diff --git a/src/impl/doge/coin/aux_chain_embedded.hpp b/src/impl/doge/coin/aux_chain_embedded.hpp index e87d5515a..a7f5bb9ea 100644 --- a/src/impl/doge/coin/aux_chain_embedded.hpp +++ b/src/impl/doge/coin/aux_chain_embedded.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase 5.5: Embedded DOGE backend for merged mining @@ -138,4 +139,4 @@ class AuxChainEmbedded : public c2pool::merged::IAuxChainBackend }; } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/doge/coin/auxpow.hpp b/src/impl/doge/coin/auxpow.hpp index 73e1022e1..7a7258e31 100644 --- a/src/impl/doge/coin/auxpow.hpp +++ b/src/impl/doge/coin/auxpow.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DOGE AuxPoW data structures — Phase 5.8 M2 (C++ class skeletons) @@ -181,4 +182,4 @@ CPureBlockHeader parse_aux_header(Stream& s, CAuxPow& out_aux, } } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/doge/coin/auxpow_header.hpp b/src/impl/doge/coin/auxpow_header.hpp index 8e30812d1..bde904c73 100644 --- a/src/impl/doge/coin/auxpow_header.hpp +++ b/src/impl/doge/coin/auxpow_header.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DOGE AuxPoW Header Parser — Phase 5.8 (M3: structured parser) @@ -128,4 +129,4 @@ inline ltc::coin::BlockType parse_doge_block(const uint8_t* data, size_t len) } } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/doge/coin/chain_params.hpp b/src/impl/doge/coin/chain_params.hpp index 376c88046..e5f2c6087 100644 --- a/src/impl/doge/coin/chain_params.hpp +++ b/src/impl/doge/coin/chain_params.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Dogecoin chain parameters for embedded SPV node. @@ -246,4 +247,4 @@ inline uint64_t get_doge_block_subsidy(uint32_t height, const DOGEChainParams& p } } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/doge/coin/chain_seeds.hpp b/src/impl/doge/coin/chain_seeds.hpp index 9670eaff4..989d35f54 100644 --- a/src/impl/doge/coin/chain_seeds.hpp +++ b/src/impl/doge/coin/chain_seeds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DNS seed hostnames and hardcoded fallback IPs for Dogecoin P2P networks. @@ -92,4 +93,4 @@ inline std::vector doge_fixed_seeds(bool testnet, bool testnet4alpha } } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/doge/coin/header_chain.hpp b/src/impl/doge/coin/header_chain.hpp index 8fd6d4537..38654f7ec 100644 --- a/src/impl/doge/coin/header_chain.hpp +++ b/src/impl/doge/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DOGE HeaderChain — Phase 5.2 // Copy of LTC header_chain.hpp with DOGE-specific difficulty (DigiShield v3) // and chain parameters. Reuses scrypt PoW, LevelDB persistence, and P2P sync. @@ -737,4 +738,4 @@ class HeaderChain { }; } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/doge/coin/template_builder.hpp b/src/impl/doge/coin/template_builder.hpp index 9a2d019e5..e1258985f 100644 --- a/src/impl/doge/coin/template_builder.hpp +++ b/src/impl/doge/coin/template_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase 5.3: DOGE Template Builder @@ -212,4 +213,4 @@ class EmbeddedCoinNode : public CoinNodeInterface { }; } // namespace coin -} // namespace doge +} // namespace doge \ No newline at end of file diff --git a/src/impl/ltc/auto_ratchet.hpp b/src/impl/ltc/auto_ratchet.hpp index dc828cf98..fbb600138 100644 --- a/src/impl/ltc/auto_ratchet.hpp +++ b/src/impl/ltc/auto_ratchet.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // AutoRatchet: autonomous share version transition state machine. @@ -350,4 +351,4 @@ class AutoRatchet } }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/block.hpp b/src/impl/ltc/coin/block.hpp index f459e087f..426835ba5 100644 --- a/src/impl/ltc/coin/block.hpp +++ b/src/impl/ltc/coin/block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // LTC block types: inherit generic headers from bitcoin_family, @@ -88,4 +89,4 @@ struct BlockType : BlockHeaderType } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/block_json.hpp b/src/impl/ltc/coin/block_json.hpp index f1be548e3..9205f9e52 100644 --- a/src/impl/ltc/coin/block_json.hpp +++ b/src/impl/ltc/coin/block_json.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// block_to_explorer_json(): Convert a BlockType into litecoind-compatible @@ -256,4 +257,4 @@ inline nlohmann::json block_to_explorer_json( } } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/chain_seeds.hpp b/src/impl/ltc/coin/chain_seeds.hpp index 47828ebf9..bc8e04c60 100644 --- a/src/impl/ltc/coin/chain_seeds.hpp +++ b/src/impl/ltc/coin/chain_seeds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DNS seed hostnames and hardcoded fallback IPs for Litecoin P2P networks. @@ -75,4 +76,4 @@ inline std::vector ltc_fixed_seeds(bool testnet) } } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/coin_node.cpp b/src/impl/ltc/coin/coin_node.cpp index da551fa7a..6f923014b 100644 --- a/src/impl/ltc/coin/coin_node.cpp +++ b/src/impl/ltc/coin/coin_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "coin_node.hpp" #include @@ -57,4 +58,4 @@ bool CoinNode::submit_block_hex(const std::string& block_hex, bool ignore_failur } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/coin_node.hpp b/src/impl/ltc/coin/coin_node.hpp index 96dff30a0..7296dd2dc 100644 --- a/src/impl/ltc/coin/coin_node.hpp +++ b/src/impl/ltc/coin/coin_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- @@ -70,4 +71,4 @@ class CoinNode : public core::coin::ICoinNode } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/compact_blocks.hpp b/src/impl/ltc/coin/compact_blocks.hpp index c7cfa8194..3adbae268 100644 --- a/src/impl/ltc/coin/compact_blocks.hpp +++ b/src/impl/ltc/coin/compact_blocks.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// BIP 152 Compact Block Support @@ -316,4 +317,4 @@ inline CompactBlockReconstructionResult ReconstructBlock( } } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/header_chain.hpp b/src/impl/ltc/coin/header_chain.hpp index 351371d52..42d1ac526 100644 --- a/src/impl/ltc/coin/header_chain.hpp +++ b/src/impl/ltc/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// LTC Header Chain — Phase 1 @@ -932,4 +933,4 @@ class HeaderChain { }; } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/mempool.hpp b/src/impl/ltc/coin/mempool.hpp index 72dfc4687..6bf7b8786 100644 --- a/src/impl/ltc/coin/mempool.hpp +++ b/src/impl/ltc/coin/mempool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// LTC Mempool — Phase 2 + UTXO fee computation @@ -732,4 +733,4 @@ class Mempool { }; } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/mweb_builder.hpp b/src/impl/ltc/coin/mweb_builder.hpp index 9e5d3a89d..77bcbb71f 100644 --- a/src/impl/ltc/coin/mweb_builder.hpp +++ b/src/impl/ltc/coin/mweb_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// MWEB (MimbleWimble Extension Block) builder for embedded LTC mode. @@ -475,4 +476,4 @@ class MWEBTracker { }; } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/node.hpp b/src/impl/ltc/coin/node.hpp index 8eeea6bdf..576d7c226 100644 --- a/src/impl/ltc/coin/node.hpp +++ b/src/impl/ltc/coin/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -93,4 +94,4 @@ class Node : public ltc::interfaces::Node } // namespace coin -} // namespace coin +} // namespace coin \ No newline at end of file diff --git a/src/impl/ltc/coin/node_interface.hpp b/src/impl/ltc/coin/node_interface.hpp index 70269f7b6..39dde9849 100644 --- a/src/impl/ltc/coin/node_interface.hpp +++ b/src/impl/ltc/coin/node_interface.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -33,6 +34,4 @@ struct Node } // namespace interfaces -} // namespace ltc::coin - - +} // namespace ltc::coin \ No newline at end of file diff --git a/src/impl/ltc/coin/p2p_connection.cpp b/src/impl/ltc/coin/p2p_connection.cpp index bd4406940..d396c71dd 100644 --- a/src/impl/ltc/coin/p2p_connection.cpp +++ b/src/impl/ltc/coin/p2p_connection.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_connection.hpp" namespace ltc @@ -37,4 +38,4 @@ void Connection::get_header(uint256 id, BlockHeaderType response) } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/p2p_connection.hpp b/src/impl/ltc/coin/p2p_connection.hpp index b40036420..e9207b3bc 100644 --- a/src/impl/ltc/coin/p2p_connection.hpp +++ b/src/impl/ltc/coin/p2p_connection.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "block.hpp" @@ -87,4 +88,4 @@ class Connection } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/p2p_messages.hpp b/src/impl/ltc/coin/p2p_messages.hpp index 2cb2a701c..1ff050329 100644 --- a/src/impl/ltc/coin/p2p_messages.hpp +++ b/src/impl/ltc/coin/p2p_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // LTC coin daemon P2P messages. diff --git a/src/impl/ltc/coin/p2p_node.cpp b/src/impl/ltc/coin/p2p_node.cpp index e7d7c257f..f1eb07578 100644 --- a/src/impl/ltc/coin/p2p_node.cpp +++ b/src/impl/ltc/coin/p2p_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "p2p_node.hpp" namespace ltc diff --git a/src/impl/ltc/coin/p2p_node.hpp b/src/impl/ltc/coin/p2p_node.hpp index f985ed6fa..03d109313 100644 --- a/src/impl/ltc/coin/p2p_node.hpp +++ b/src/impl/ltc/coin/p2p_node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "p2p_messages.hpp" @@ -995,4 +996,4 @@ class NodeP2P : public core::ICommunicator, public core::INetwork, public core:: } // namespace node -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/rpc.cpp b/src/impl/ltc/coin/rpc.cpp index 2588436a8..f1705d0fd 100644 --- a/src/impl/ltc/coin/rpc.cpp +++ b/src/impl/ltc/coin/rpc.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "rpc.hpp" #include diff --git a/src/impl/ltc/coin/rpc.hpp b/src/impl/ltc/coin/rpc.hpp index df1f64e6c..10cad8899 100644 --- a/src/impl/ltc/coin/rpc.hpp +++ b/src/impl/ltc/coin/rpc.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "block.hpp" @@ -92,6 +93,4 @@ struct RPCAuthData } // namespace coin -} // namespace ltc - - +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/rpc_data.hpp b/src/impl/ltc/coin/rpc_data.hpp index 3d9a4dcbd..b20ac61d4 100644 --- a/src/impl/ltc/coin/rpc_data.hpp +++ b/src/impl/ltc/coin/rpc_data.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/impl/ltc/coin/softfork_check.hpp b/src/impl/ltc/coin/softfork_check.hpp index 003459124..63e11beff 100644 --- a/src/impl/ltc/coin/softfork_check.hpp +++ b/src/impl/ltc/coin/softfork_check.hpp @@ -1,6 +1,7 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Forwarding header: generic softfork check moved to bitcoin_family #include namespace ltc { namespace coin { using bitcoin_family::coin::collect_softfork_names; -}} +}} \ No newline at end of file diff --git a/src/impl/ltc/coin/template_builder.hpp b/src/impl/ltc/coin/template_builder.hpp index aa5e796cd..719589b56 100644 --- a/src/impl/ltc/coin/template_builder.hpp +++ b/src/impl/ltc/coin/template_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// Phase 3: LTC Template Builder @@ -399,4 +400,4 @@ class EmbeddedCoinNode : public CoinNodeInterface { }; } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/transaction.cpp b/src/impl/ltc/coin/transaction.cpp index 97f161b7e..b75d550ee 100644 --- a/src/impl/ltc/coin/transaction.cpp +++ b/src/impl/ltc/coin/transaction.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "transaction.hpp" namespace ltc diff --git a/src/impl/ltc/coin/transaction.hpp b/src/impl/ltc/coin/transaction.hpp index 9abef68a4..c7e61e93e 100644 --- a/src/impl/ltc/coin/transaction.hpp +++ b/src/impl/ltc/coin/transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // LTC transaction types: import generic primitives from bitcoin_family, @@ -232,4 +233,4 @@ void SerializeTransaction(const TxType& tx, StreamType& s, const TxParams& param } // namespace coin -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/coin/txidcache.hpp b/src/impl/ltc/coin/txidcache.hpp index f8ed5723b..d93b49d13 100644 --- a/src/impl/ltc/coin/txidcache.hpp +++ b/src/impl/ltc/coin/txidcache.hpp @@ -1,6 +1,7 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Forwarding header: generic TXIDCache moved to bitcoin_family #include namespace ltc { namespace coin { using bitcoin_family::coin::TXIDCache; -}} +}} \ No newline at end of file diff --git a/src/impl/ltc/config.hpp b/src/impl/ltc/config.hpp index 7fef6a1c6..5565fb24b 100644 --- a/src/impl/ltc/config.hpp +++ b/src/impl/ltc/config.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "config_pool.hpp" @@ -8,4 +9,4 @@ namespace ltc using Config = core::Config; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/config_coin.cpp b/src/impl/ltc/config_coin.cpp index e06873986..119a8cca6 100644 --- a/src/impl/ltc/config_coin.cpp +++ b/src/impl/ltc/config_coin.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_coin.hpp" #include @@ -32,4 +33,4 @@ void CoinConfig::load() PARSE_CONFIG(node, testnet, bool); } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/config_coin.hpp b/src/impl/ltc/config_coin.hpp index b9dd39b82..18e05ba4a 100644 --- a/src/impl/ltc/config_coin.hpp +++ b/src/impl/ltc/config_coin.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -101,4 +102,4 @@ class CoinConfig : protected core::Fileconfig // uint256 dumb_scrypt_diff; }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/config_pool.cpp b/src/impl/ltc/config_pool.cpp index 605051ea7..7aab44afe 100644 --- a/src/impl/ltc/config_pool.cpp +++ b/src/impl/ltc/config_pool.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "config_pool.hpp" #include @@ -45,4 +46,4 @@ void PoolConfig::load() } } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/config_pool.hpp b/src/impl/ltc/config_pool.hpp index 97be3296b..869a1a323 100644 --- a/src/impl/ltc/config_pool.hpp +++ b/src/impl/ltc/config_pool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -234,4 +235,4 @@ class PoolConfig : protected core::Fileconfig std::vector m_bootstrap_addrs; }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/donation_consensus.hpp b/src/impl/ltc/donation_consensus.hpp index 4ab5ddc94..1d6234965 100644 --- a/src/impl/ltc/donation_consensus.hpp +++ b/src/impl/ltc/donation_consensus.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // // donation_consensus.hpp — Consensus-level donation script validation for LTC p2pool shares. @@ -120,4 +121,4 @@ build_expected_payouts(ShareTracker& tracker, return tracker.get_expected_payouts(best_share_hash, block_target, subsidy, donation_script); } -} // namespace ltc::consensus +} // namespace ltc::consensus \ No newline at end of file diff --git a/src/impl/ltc/messages.hpp b/src/impl/ltc/messages.hpp index 71389facd..b006f0312 100644 --- a/src/impl/ltc/messages.hpp +++ b/src/impl/ltc/messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/block.hpp" @@ -188,4 +189,4 @@ using Handler = MessageHandler< message_remember_tx >; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/node.cpp b/src/impl/ltc/node.cpp index e71dd665f..310bcacc6 100644 --- a/src/impl/ltc/node.cpp +++ b/src/impl/ltc/node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include @@ -2406,4 +2407,4 @@ void NodeImpl::set_rss_limit_mb(long mb) g_rss_limit_mb = mb; } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/node.hpp b/src/impl/ltc/node.hpp index d8e8bbbea..0e048ef0e 100644 --- a/src/impl/ltc/node.hpp +++ b/src/impl/ltc/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "config.hpp" @@ -647,4 +648,4 @@ class Actual : public pool::Protocol using Node = pool::NodeBridge; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/params.hpp b/src/impl/ltc/params.hpp index ec5f91a37..c58f68889 100644 --- a/src/impl/ltc/params.hpp +++ b/src/impl/ltc/params.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // LTC CoinParams factory: creates a fully populated CoinParams for Litecoin. @@ -131,4 +132,4 @@ inline core::CoinParams make_coin_params(bool testnet) return p; } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/peer.hpp b/src/impl/ltc/peer.hpp index 804e6d788..953d0d000 100644 --- a/src/impl/ltc/peer.hpp +++ b/src/impl/ltc/peer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/transaction.hpp" diff --git a/src/impl/ltc/pool_monitor.hpp b/src/impl/ltc/pool_monitor.hpp index 88ca2f156..ca377f7bd 100644 --- a/src/impl/ltc/pool_monitor.hpp +++ b/src/impl/ltc/pool_monitor.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 3L: Log-based pool monitoring for attack detection. @@ -357,4 +358,4 @@ class PoolMonitor } }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/protocol_actual.cpp b/src/impl/ltc/protocol_actual.cpp index b6e61a039..72b0ff23e 100644 --- a/src/impl/ltc/protocol_actual.cpp +++ b/src/impl/ltc/protocol_actual.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" @@ -271,4 +272,4 @@ void Actual::HANDLER(forget_tx) } } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/protocol_legacy.cpp b/src/impl/ltc/protocol_legacy.cpp index 7d19af899..fba7ccb12 100644 --- a/src/impl/ltc/protocol_legacy.cpp +++ b/src/impl/ltc/protocol_legacy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" #include "share.hpp" diff --git a/src/impl/ltc/redistribute.hpp b/src/impl/ltc/redistribute.hpp index cfe965e5c..44a684f6c 100644 --- a/src/impl/ltc/redistribute.hpp +++ b/src/impl/ltc/redistribute.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Redistribute V2: advanced redistribution policy for shares from miners @@ -496,4 +497,4 @@ class Redistributor } }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/share.hpp b/src/impl/ltc/share.hpp index e5be74946..d98022e9b 100644 --- a/src/impl/ltc/share.hpp +++ b/src/impl/ltc/share.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "coin/block.hpp" @@ -312,5 +313,4 @@ struct ShareChain : chain::ShareChain }; -} // namespace ltc - +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/share_check.hpp b/src/impl/ltc/share_check.hpp index 9456de357..5e33fe9de 100644 --- a/src/impl/ltc/share_check.hpp +++ b/src/impl/ltc/share_check.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // P2: Share verification — check_hash_link, check_merkle_link, share init/check @@ -3350,4 +3351,4 @@ uint256 create_local_share( return share_hash; } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/share_messages.hpp b/src/impl/ltc/share_messages.hpp index f05c12783..a89d83067 100644 --- a/src/impl/ltc/share_messages.hpp +++ b/src/impl/ltc/share_messages.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // share_messages.hpp — V36 share-embedded messaging: decryption + validation // // Port of p2pool/share_messages.py (consensus-critical portions). @@ -576,4 +577,4 @@ inline std::vector create_message_data( return encrypt_message_envelope(inner, authority_pubkey); } -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/share_tracker.hpp b/src/impl/ltc/share_tracker.hpp index 5c05e04c3..72dfea864 100644 --- a/src/impl/ltc/share_tracker.hpp +++ b/src/impl/ltc/share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Portable 128-bit multiply-shift: (a * b) >> shift @@ -2875,4 +2876,4 @@ class ShareTracker CumulativeWeights m_decayed_cache_result; }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/share_types.hpp b/src/impl/ltc/share_types.hpp index f4eee610a..6e2d8d901 100644 --- a/src/impl/ltc/share_types.hpp +++ b/src/impl/ltc/share_types.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -193,4 +194,4 @@ struct AbsworkV36Format } }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/ltc/test/emergency_decay_overflow_test.cpp b/src/impl/ltc/test/emergency_decay_overflow_test.cpp index 04459b70e..9d234e454 100644 --- a/src/impl/ltc/test/emergency_decay_overflow_test.cpp +++ b/src/impl/ltc/test/emergency_decay_overflow_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Conformance KAT — death-spiral emergency-decay uint256 overflow. // // Guards ltc::ShareTracker::emergency_decay_shl (Step 3 of @@ -92,4 +93,4 @@ TEST(EmergencyDecayOverflow, NeverDecreasesTarget) ASSERT_TRUE(r >= prev) << "prev=" << prev.GetHex() << " shift=" << shift; ASSERT_TRUE(r <= MAX_T) << "prev=" << prev.GetHex() << " shift=" << shift; } -} +} \ No newline at end of file diff --git a/src/impl/ltc/test/f11_donation_invariance_test.cpp b/src/impl/ltc/test/f11_donation_invariance_test.cpp index 9780d1b78..f8c8541b3 100644 --- a/src/impl/ltc/test/f11_donation_invariance_test.cpp +++ b/src/impl/ltc/test/f11_donation_invariance_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // F11 value-invariance KAT — guards the canonical exclude-then-append donation // handling in the LTC v36 payout sort (src/impl/ltc/share_check.hpp, // build_payout_outputs_excluding_donation). @@ -179,4 +180,4 @@ TEST(LTC_F11_DonationInvariance, RealDonationConstantsPinned) { EXPECT_EQ(p.back(), 0xac); EXPECT_NE(c, p); -} +} \ No newline at end of file diff --git a/src/impl/ltc/test/share_test.cpp b/src/impl/ltc/test/share_test.cpp index 01eab95de..292704f99 100644 --- a/src/impl/ltc/test/share_test.cpp +++ b/src/impl/ltc/test/share_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // PackStream stream_share; // stream_share.from_hex("21fd0702fe02000020617dfa46bf73eb96548e0b039a647d35b387ed0cb1a6e51c80092175857d3f5b3ac4ff62f1a9001bc0254dda4d00fe065ba137d8e108ef134db29b7e33f46327f13626975c0c2a190082018f3d04d03aee002cfabe6d6d21102609e852babee96639fbb3b65588bbcc419720fec56da52e47120c4804a501000000000000000a5f5f6332706f6f6c5f5ffc88aa669a2cd3c1310067ae7e47a7869b330d30b691c61b46fb483b0a0000000000002102f24e44938c7bde43245d2a17c7fe424fbebc63f05317dfdace08a95a2f10d5efe4248d9eb63c2de431a93f0c94e857920cb3f70163dba595de7720e6cc014203517d2164368b766e6b9d0598510a7bbfc9882940ebfe3f65bb72173c3dbf105802f24e44938c7bde43245d2a17c7fe424fbebc63f05317dfdace08a95a2f10d5ef1025a29236b072d75cde8637584a3ed2fe0bcd4aadb5824b61cc42b4414e143d020000000195cbb26f405ead27fcd8cf84155cfcfab722a0cfdb3a2c735fce15fb19bc8ae4ffff0f1e8888001e3bc4ff62cc210000df798a25160000000000000000000000000000000001000000986dae33074d8c439a5dc61c2019a86726ebd1cf0eb0240582ccc0b249d12ba7fd9c0102f24e44938c7bde43245d2a17c7fe424fbebc63f05317dfdace08a95a2f10d5efe4248d9eb63c2de431a93f0c94e857920cb3f70163dba595de7720e6cc014203"); diff --git a/src/impl/ltc/whale_departure.hpp b/src/impl/ltc/whale_departure.hpp index b39fe9b8c..7826aff68 100644 --- a/src/impl/ltc/whale_departure.hpp +++ b/src/impl/ltc/whale_departure.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // Phase 1c: Whale departure recovery — non-consensus local heuristic. @@ -190,4 +191,4 @@ class WhaleDepartureDetector uint32_t gap_trigger_periods_ = 8; // share gap trigger }; -} // namespace ltc +} // namespace ltc \ No newline at end of file diff --git a/src/impl/nmc/coin/aux_chain_embedded.hpp b/src/impl/nmc/coin/aux_chain_embedded.hpp index 33a0cfe6d..41f21fec6 100644 --- a/src/impl/nmc/coin/aux_chain_embedded.hpp +++ b/src/impl/nmc/coin/aux_chain_embedded.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// P1 PD: Embedded NMC (Namecoin) backend for merge-mining under a BTC parent. @@ -198,4 +199,4 @@ class AuxChainEmbedded : public c2pool::merged::IAuxChainBackend }; } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/aux_id.hpp b/src/impl/nmc/coin/aux_id.hpp index ab75d3377..539f9c356 100644 --- a/src/impl/nmc/coin/aux_id.hpp +++ b/src/impl/nmc/coin/aux_id.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -20,4 +21,4 @@ namespace coin { inline constexpr uint32_t NMC_AUXPOW_CHAIN_ID = 0x0001; } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/block.hpp b/src/impl/nmc/coin/block.hpp index e6cdf9b45..62d5ce7f9 100644 --- a/src/impl/nmc/coin/block.hpp +++ b/src/impl/nmc/coin/block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // NMC (Namecoin) block / header primitives. @@ -124,4 +125,4 @@ struct BlockType : BlockHeaderType } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/block_assembly.hpp b/src/impl/nmc/coin/block_assembly.hpp index 852515eb3..a23d44a11 100644 --- a/src/impl/nmc/coin/block_assembly.hpp +++ b/src/impl/nmc/coin/block_assembly.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // nmc::coin::assemble_won_block -- the won-share->parent-block "as_block" @@ -110,4 +111,4 @@ assemble_won_block(const SmallBlockHeaderType& small_header, } } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/block_broadcast.hpp b/src/impl/nmc/coin/block_broadcast.hpp index a1d55ab8c..a911c102d 100644 --- a/src/impl/nmc/coin/block_broadcast.hpp +++ b/src/impl/nmc/coin/block_broadcast.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // nmc::coin::broadcast_won_aux_block -- the NMC (Namecoin) dual-path won-block @@ -147,4 +148,4 @@ inline AuxBlockBroadcast broadcast_won_aux_block(const P2pRelaySink& p2p_relay, } } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/chain_seeds.hpp b/src/impl/nmc/coin/chain_seeds.hpp index 6a448b83c..2e6805a58 100644 --- a/src/impl/nmc/coin/chain_seeds.hpp +++ b/src/impl/nmc/coin/chain_seeds.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// DNS seed hostnames and hardcoded fallback IPs for Namecoin P2P networks. @@ -71,4 +72,4 @@ inline std::vector nmc_fixed_seeds(bool testnet) } } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/coin_smoke.cpp b/src/impl/nmc/coin/coin_smoke.cpp index ca75748ba..92e87ed49 100644 --- a/src/impl/nmc/coin/coin_smoke.cpp +++ b/src/impl/nmc/coin/coin_smoke.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // NMC coin P0 structural-leaf smoke translation unit. // // Header-only NMC coin types (block.hpp, header_chain.hpp) are otherwise never @@ -60,4 +61,4 @@ void nmc_coin_p0_smoke() } } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/header_chain.hpp b/src/impl/nmc/coin/header_chain.hpp index 98d9d6901..1a3e2313f 100644 --- a/src/impl/nmc/coin/header_chain.hpp +++ b/src/impl/nmc/coin/header_chain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// NMC (Namecoin) Header Chain — embedded merge-mined Namecoin @@ -1404,4 +1405,4 @@ class HeaderChain { }; } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/mempool.hpp b/src/impl/nmc/coin/mempool.hpp index fb64cf557..de585ee05 100644 --- a/src/impl/nmc/coin/mempool.hpp +++ b/src/impl/nmc/coin/mempool.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// NMC (Namecoin) Mempool — embedded merge-mined tx pool (P1 PB). @@ -845,4 +846,4 @@ class Mempool { }; } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/reconstruct_won_block.hpp b/src/impl/nmc/coin/reconstruct_won_block.hpp index 8a571bd71..c593fe4a0 100644 --- a/src/impl/nmc/coin/reconstruct_won_block.hpp +++ b/src/impl/nmc/coin/reconstruct_won_block.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // --------------------------------------------------------------------------- // nmc::coin::reconstruct_won_block_from_template -- the CORRECT won-block @@ -82,4 +83,4 @@ reconstruct_won_block_from_template( } } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/rpc_data.hpp b/src/impl/nmc/coin/rpc_data.hpp index a0ababe6f..48a581c97 100644 --- a/src/impl/nmc/coin/rpc_data.hpp +++ b/src/impl/nmc/coin/rpc_data.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // NMC (Namecoin) RPC work-data type. @@ -45,4 +46,4 @@ struct WorkData } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/template_builder.hpp b/src/impl/nmc/coin/template_builder.hpp index 1e02e8fbf..e927e6db7 100644 --- a/src/impl/nmc/coin/template_builder.hpp +++ b/src/impl/nmc/coin/template_builder.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /// P1 PC: NMC (Namecoin) Template Builder @@ -354,4 +355,4 @@ class EmbeddedCoinNode : public CoinNodeInterface { }; } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/transaction.cpp b/src/impl/nmc/coin/transaction.cpp index 22179e68b..e6a6e4364 100644 --- a/src/impl/nmc/coin/transaction.cpp +++ b/src/impl/nmc/coin/transaction.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "transaction.hpp" namespace nmc @@ -21,4 +22,4 @@ MutableTransaction::MutableTransaction(const Transaction& tx) : version(tx.versi } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/coin/transaction.hpp b/src/impl/nmc/coin/transaction.hpp index c61f9849b..bec420ef1 100644 --- a/src/impl/nmc/coin/transaction.hpp +++ b/src/impl/nmc/coin/transaction.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once // NMC (Namecoin) transaction primitives. @@ -225,4 +226,4 @@ void SerializeTransaction(const TxType& tx, StreamType& s, const TxParams& param } // namespace coin -} // namespace nmc +} // namespace nmc \ No newline at end of file diff --git a/src/impl/nmc/test/auxpow_merkle_test.cpp b/src/impl/nmc/test/auxpow_merkle_test.cpp index 39399be6b..8c63602c6 100644 --- a/src/impl/nmc/test/auxpow_merkle_test.cpp +++ b/src/impl/nmc/test/auxpow_merkle_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc::coin::aux_merkle_root KAT (P1 — AuxPow merkle-proof walk). // @@ -2022,4 +2023,4 @@ TEST(NmcChainIdPin, WrongExpectedChainIdBreaksSlotBinding) // so the staged MATCH is lost; never INCOMPLETE, never VALID. EXPECT_NE(ap.check_proof(aux, wrong), AuxPow::CheckResult::INCOMPLETE); EXPECT_NE(ap.check_proof(aux, wrong), AuxPow::CheckResult::VALID); -} +} \ No newline at end of file diff --git a/src/impl/nmc/test/auxpow_wire_test.cpp b/src/impl/nmc/test/auxpow_wire_test.cpp index fc79664fb..a618bba2d 100644 --- a/src/impl/nmc/test/auxpow_wire_test.cpp +++ b/src/impl/nmc/test/auxpow_wire_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc::coin::AuxPow wire-vector KAT (P1 / card 237 — real mainnet round-trip). // @@ -382,4 +383,4 @@ TEST(NmcPFConsensusPin, PowLimitAndGenesisMatchNamecoinCore) EXPECT_FALSE(main.genesis_hash.IsNull()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/nmc/test/nmc_block_broadcast_test.cpp b/src/impl/nmc/test/nmc_block_broadcast_test.cpp index 393174f81..b734c17db 100644 --- a/src/impl/nmc/test/nmc_block_broadcast_test.cpp +++ b/src/impl/nmc/test/nmc_block_broadcast_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc::coin::broadcast_won_aux_block dual-path dispatcher test (PE item 3, // broadcaster-gate dispatcher half). @@ -156,4 +157,4 @@ TEST(NmcAuxBlockBroadcast, ThrowingRpcDoesNotMaskP2pWin) { EXPECT_FALSE(r.rpc_ok); EXPECT_TRUE(r.any()); EXPECT_STREQ(r.landed_first, "p2p"); -} +} \ No newline at end of file diff --git a/src/impl/nmc/test/nmc_fallback_path_conformance_test.cpp b/src/impl/nmc/test/nmc_fallback_path_conformance_test.cpp index 39a472571..104df4237 100644 --- a/src/impl/nmc/test/nmc_fallback_path_conformance_test.cpp +++ b/src/impl/nmc/test/nmc_fallback_path_conformance_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc PF fallback-path conformance lock (Phase PF, external-daemon-fallback half). // @@ -123,4 +124,4 @@ TEST(NmcPfFallbackPath, ExternalFallbackPersistsAlongsideWorkingEmbeddedP2p) { EXPECT_TRUE(r.rpc_ok); // retained fallback fired anyway EXPECT_EQ(ext.calls, 1); // ALWAYS-fired, not skipped because P2P won EXPECT_STREQ(r.landed_first, "p2p"); // primary still won the race -} +} \ No newline at end of file diff --git a/src/impl/nmc/test/nmc_host_dualpath_test.cpp b/src/impl/nmc/test/nmc_host_dualpath_test.cpp index c79462f2d..09f989aa0 100644 --- a/src/impl/nmc/test/nmc_host_dualpath_test.cpp +++ b/src/impl/nmc/test/nmc_host_dualpath_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc host-level dual-path won-aux broadcaster regression-lock (PE item 3, // HOST-wiring half). NET-NEW vs the helper-level nmc_block_broadcast_test: @@ -238,4 +239,4 @@ TEST(NmcHostDualPath, NeitherLegBoundNeverSilentDrops) { EXPECT_FALSE(bc.rpc_ok); EXPECT_EQ(p2p.calls, 0); EXPECT_STREQ(bc.landed_first, "none"); -} +} \ No newline at end of file diff --git a/src/impl/nmc/test/nmc_mempool_name_test.cpp b/src/impl/nmc/test/nmc_mempool_name_test.cpp index 224e8055d..6a2168709 100644 --- a/src/impl/nmc/test/nmc_mempool_name_test.cpp +++ b/src/impl/nmc/test/nmc_mempool_name_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc::coin::Mempool — Namecoin name-operation relay KATs (P1 PB). // @@ -232,4 +233,4 @@ TEST(NmcNameFee, NameTxFeeReachesTemplateCoinbaseValue) EXPECT_EQ(d.at("transactions").size(), 1u); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/nmc/test/nmc_template_builder_test.cpp b/src/impl/nmc/test/nmc_template_builder_test.cpp index 7baddb696..f08530cec 100644 --- a/src/impl/nmc/test/nmc_template_builder_test.cpp +++ b/src/impl/nmc/test/nmc_template_builder_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc::coin::TemplateBuilder KATs (P1 PC - embedded template builder). // @@ -389,4 +390,4 @@ TEST(NmcAuxChainEmbedded, SubmitAuxBlockRpcLegSurfacesFalseInEmbeddedMode) } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/impl/nmc/test/reconstruct_won_block_test.cpp b/src/impl/nmc/test/reconstruct_won_block_test.cpp index 7236e2fce..2dd392bf3 100644 --- a/src/impl/nmc/test/reconstruct_won_block_test.cpp +++ b/src/impl/nmc/test/reconstruct_won_block_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // nmc_reconstruct_won_block_test -- pins coin/reconstruct_won_block.hpp + // coin/block_assembly.hpp, the PE-2e (#251) won-block reconstructor. Mirrors @@ -244,4 +245,4 @@ TEST(NmcReconstructWonBlock, NonEmptyBranchRecomputesRootViaSsot) EXPECT_NE(blk.m_merkle_root, share.gentx_hash); } -} // namespace +} // namespace \ No newline at end of file diff --git a/src/pool/node.cpp b/src/pool/node.cpp index 567da1230..8658a76f3 100644 --- a/src/pool/node.cpp +++ b/src/pool/node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "node.hpp" namespace pool diff --git a/src/pool/node.hpp b/src/pool/node.hpp index cdc66edbb..57dbb1d57 100644 --- a/src/pool/node.hpp +++ b/src/pool/node.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -258,4 +259,4 @@ class NodeBridge : public virtual Base, public Legacy, public Actual #define HANDLER(name)\ handle (std::unique_ptr msg, peer_ptr peer) -} // namespace pool +} // namespace pool \ No newline at end of file diff --git a/src/pool/peer.hpp b/src/pool/peer.hpp index 027dc7bb2..db2a12b61 100644 --- a/src/pool/peer.hpp +++ b/src/pool/peer.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/pool/protocol.hpp b/src/pool/protocol.hpp index c26608c2a..694aa7c5d 100644 --- a/src/pool/protocol.hpp +++ b/src/pool/protocol.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/sharechain/legacy/base_share_tracker.hpp b/src/sharechain/legacy/base_share_tracker.hpp index c3c093951..afa47534d 100644 --- a/src/sharechain/legacy/base_share_tracker.hpp +++ b/src/sharechain/legacy/base_share_tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -99,4 +100,4 @@ class VerifiedShareTracker : public BaseShareTracker { return _share_tracker.get_nth_parent_key(hash, n); } -}; +}; \ No newline at end of file diff --git a/src/sharechain/legacy/cluster.hpp b/src/sharechain/legacy/cluster.hpp index 2a96fcf0d..94a4e7bd0 100644 --- a/src/sharechain/legacy/cluster.hpp +++ b/src/sharechain/legacy/cluster.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include #include diff --git a/src/sharechain/legacy/fork.hpp b/src/sharechain/legacy/fork.hpp index eb5d11b8f..fdd9cc05a 100644 --- a/src/sharechain/legacy/fork.hpp +++ b/src/sharechain/legacy/fork.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include #include diff --git a/src/sharechain/legacy/prefsum_weights.hpp b/src/sharechain/legacy/prefsum_weights.hpp index 32d18b09b..dbc007511 100644 --- a/src/sharechain/legacy/prefsum_weights.hpp +++ b/src/sharechain/legacy/prefsum_weights.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include #include diff --git a/src/sharechain/legacy/rules.hpp b/src/sharechain/legacy/rules.hpp index 330910c05..71461754a 100644 --- a/src/sharechain/legacy/rules.hpp +++ b/src/sharechain/legacy/rules.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include diff --git a/src/sharechain/legacy/tracker.hpp b/src/sharechain/legacy/tracker.hpp index f7ceef76e..dc4b48336 100644 --- a/src/sharechain/legacy/tracker.hpp +++ b/src/sharechain/legacy/tracker.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include #include diff --git a/src/sharechain/prepared_list.hpp b/src/sharechain/prepared_list.hpp index ab6eafc6d..98950ffbf 100644 --- a/src/sharechain/prepared_list.hpp +++ b/src/sharechain/prepared_list.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -201,4 +202,4 @@ struct PreparedList }; }; -} // namespace chain +} // namespace chain \ No newline at end of file diff --git a/src/sharechain/share.hpp b/src/sharechain/share.hpp index 985203a76..36150f2dd 100644 --- a/src/sharechain/share.hpp +++ b/src/sharechain/share.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -168,5 +169,4 @@ typename ShareVariants::load_map ShareVariants\ static void Read(StreamType &stream, ShareT* obj) { FormatAction(stream, obj, UnserializeFormatter{}); }\ template\ - static void FormatAction(StreamType &stream, ShareT* obj, StreamFormatter formatter) - + static void FormatAction(StreamType &stream, ShareT* obj, StreamFormatter formatter) \ No newline at end of file diff --git a/src/sharechain/sharechain.cpp b/src/sharechain/sharechain.cpp index 5604e8e44..d81443819 100644 --- a/src/sharechain/sharechain.cpp +++ b/src/sharechain/sharechain.cpp @@ -1 +1,2 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "sharechain.hpp" \ No newline at end of file diff --git a/src/sharechain/sharechain.hpp b/src/sharechain/sharechain.hpp index 19bdd4bd2..04c1fd850 100644 --- a/src/sharechain/sharechain.hpp +++ b/src/sharechain/sharechain.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "skip_list.hpp" diff --git a/src/sharechain/skip_list.hpp b/src/sharechain/skip_list.hpp index afcd282c4..bb93a63ac 100644 --- a/src/sharechain/skip_list.hpp +++ b/src/sharechain/skip_list.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /** * p2pool DistanceSkipList — O(log n) amortized ancestor lookups. @@ -232,4 +233,4 @@ class DistanceSkipList bool contains(const hash_t& hash) const { return m_skips.contains(hash); } }; -} // namespace chain +} // namespace chain \ No newline at end of file diff --git a/src/sharechain/stats_skiplist.hpp b/src/sharechain/stats_skiplist.hpp index a7ffa4bdd..e6bb0cc04 100644 --- a/src/sharechain/stats_skiplist.hpp +++ b/src/sharechain/stats_skiplist.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // stats_skiplist.hpp — O(log n) sharechain statistics via probabilistic skip list // // Same pattern as weights_skiplist.hpp but aggregates dashboard stats @@ -233,4 +234,4 @@ class StatsSkipList std::unordered_map m_nodes; }; -} // namespace chain +} // namespace chain \ No newline at end of file diff --git a/src/sharechain/test/share_test.cpp b/src/sharechain/test/share_test.cpp index f19e9eb7d..905652406 100644 --- a/src/sharechain/test/share_test.cpp +++ b/src/sharechain/test/share_test.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include -#include +#include \ No newline at end of file diff --git a/src/sharechain/tracker_view.hpp b/src/sharechain/tracker_view.hpp index e960d66b9..3b2ced837 100644 --- a/src/sharechain/tracker_view.hpp +++ b/src/sharechain/tracker_view.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once /** * TrackerView — C++ implementation of p2pool forest.py TrackerView. @@ -365,4 +366,4 @@ class TrackerView } }; -} // namespace chain +} // namespace chain \ No newline at end of file diff --git a/src/sharechain/weights_skiplist.hpp b/src/sharechain/weights_skiplist.hpp index c0602f672..0f9defcc1 100644 --- a/src/sharechain/weights_skiplist.hpp +++ b/src/sharechain/weights_skiplist.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // weights_skiplist.hpp — O(log n) PPLNS weight computation via skip list // // Faithful port of: @@ -356,4 +357,4 @@ class WeightsSkipList std::unordered_map m_skips; }; -} // namespace chain +} // namespace chain \ No newline at end of file diff --git a/test/test_address_resolution.cpp b/test/test_address_resolution.cpp index a9c122b5c..fa840baff 100644 --- a/test/test_address_resolution.cpp +++ b/test/test_address_resolution.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Tests for merged mining address resolution: * - Cases 2a-2c: Auto-derivation (LTC P2PKH/P2WPKH/P2SH → merged chain script) @@ -544,4 +545,4 @@ TEST(ResendGate, EmptyUsername_NeverFires) EXPECT_FALSE(o.merged_nonempty); EXPECT_EQ(o.new_fires, 0); EXPECT_FALSE(o.old_would_fire); -} +} \ No newline at end of file diff --git a/test/test_auto_ratchet.cpp b/test/test_auto_ratchet.cpp index ee589c74c..ef4e57ab5 100644 --- a/test/test_auto_ratchet.cpp +++ b/test/test_auto_ratchet.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -252,4 +253,4 @@ TEST(AutoRatchetTest, MonotonicCounter_NoDecrease) confirm_count += (new_height - last_height); // Counter unchanged EXPECT_EQ(confirm_count, 100); -} +} \ No newline at end of file diff --git a/test/test_blockchain_integration.cpp b/test/test_blockchain_integration.cpp index 5f429a378..493c07540 100644 --- a/test/test_blockchain_integration.cpp +++ b/test/test_blockchain_integration.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /* * Comprehensive Blockchain Integration Test for C2Pool * @@ -534,4 +535,4 @@ int main() { } return 0; -} +} \ No newline at end of file diff --git a/test/test_coin_broadcaster.cpp b/test/test_coin_broadcaster.cpp index ccca84cde..b64091afa 100644 --- a/test/test_coin_broadcaster.cpp +++ b/test/test_coin_broadcaster.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -914,4 +915,4 @@ int main(int argc, char** argv) { ::testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); -} +} \ No newline at end of file diff --git a/test/test_coinbase_standalone.cpp b/test/test_coinbase_standalone.cpp index cfeec5274..b12731be6 100644 --- a/test/test_coinbase_standalone.cpp +++ b/test/test_coinbase_standalone.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -123,4 +124,4 @@ int main() { std::cout << "❌ Test failed with exception: " << e.what() << std::endl; return 1; } -} +} \ No newline at end of file diff --git a/test/test_compact_blocks.cpp b/test/test_compact_blocks.cpp index 5cef559b8..fb3956123 100644 --- a/test/test_compact_blocks.cpp +++ b/test/test_compact_blocks.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// BIP 152 Compact Block unit tests /// /// Tests: @@ -382,4 +383,4 @@ TEST(CompactBlockTest, CompressionRatio) { EXPECT_LT(ratio, 0.5) << "Compact block should be <50% of full block size" << " (full=" << full_size << ", compact=" << compact_size << ", ratio=" << ratio << ")"; -} +} \ No newline at end of file diff --git a/test/test_compute_share_target.cpp b/test/test_compute_share_target.cpp index 36016ee79..331cdb66f 100644 --- a/test/test_compute_share_target.cpp +++ b/test/test_compute_share_target.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Cross-implementation tests for compute_share_target(). * @@ -289,4 +290,4 @@ TEST(ComputeShareTarget, APSMatchesPython) { EXPECT_EQ(chain::target_to_bits_upper_bound(pre_target), chain::target_to_bits_upper_bound(max_target)) << "pre_target should equal MAX_TARGET for uniform chain"; -} +} \ No newline at end of file diff --git a/test/test_dash_auto_ratchet.cpp b/test/test_dash_auto_ratchet.cpp index e0c359753..0af046f87 100644 --- a/test/test_dash_auto_ratchet.cpp +++ b/test/test_dash_auto_ratchet.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH v36-native MINT-side accept-floor auto-ratchet KAT. // // FENCED, additive (no production call site touched -- pins the pure free functions @@ -175,4 +176,4 @@ TEST(DashAutoRatchetWiring, AlreadyAtTargetShortCircuits) { auto w = std::map{{36, u(100)}}; EXPECT_EQ(dash::apply_min_protocol_ratchet_decision(CL, CL, w, 36, TARGET, TARGET), TARGET); EXPECT_EQ(dash::apply_min_protocol_ratchet_decision(0, CL, w, 36, TARGET, TARGET), TARGET); -} +} \ No newline at end of file diff --git a/test/test_dash_block_producer.cpp b/test/test_dash_block_producer.cpp index 682fa3746..00f8f900b 100644 --- a/test/test_dash_block_producer.cpp +++ b/test/test_dash_block_producer.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH block PRODUCER KAT (launcher slice 5) — NETWORK-FREE. // // Pins the producer primitives that turn an embedded/dashd block template into @@ -254,4 +255,4 @@ TEST(DashBlockProducer, Bip34HeightOpNForm) EXPECT_EQ(push_bip34_height(17), (std::vector{0x01, 0x11})); // Sign-byte avoidance still holds on the data-push branch: 128 -> [2][80][00]. EXPECT_EQ(push_bip34_height(128), (std::vector{0x02, 0x80, 0x00})); -} +} \ No newline at end of file diff --git a/test/test_dash_block_relay.cpp b/test/test_dash_block_relay.cpp index 8324db67c..fd141aa64 100644 --- a/test/test_dash_block_relay.cpp +++ b/test/test_dash_block_relay.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — WonBlockRelay (embedded-P2P won-block relay framer) KATs. /// /// Exercises src/impl/dash/block_relay.hpp — the framing half of the @@ -141,4 +142,4 @@ TEST(DashWonBlockRelay, ReAnnounce_SameHash_IsIdempotentRefresh) { ASSERT_NE(rmsg, nullptr); auto parsed = message_block::make(rmsg->m_data); EXPECT_EQ(parsed->m_block.m_nonce, make_block(9).m_nonce); // latest wins -} +} \ No newline at end of file diff --git a/test/test_dash_block_relay_binding.cpp b/test/test_dash_block_relay_binding.cpp index 71b360701..f153d27bc 100644 --- a/test/test_dash_block_relay_binding.cpp +++ b/test/test_dash_block_relay_binding.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — WonBlockRelay <-> DashBroadcaster binding KATs. /// /// Exercises src/impl/dash/block_relay_binding.hpp — the adapter that pulls the @@ -254,4 +255,4 @@ TEST(DashRelayBinding, LiveFanoutObserverDoesNotRecord) EXPECT_EQ(binding.live_fanout(), 2u); EXPECT_EQ(relay.pending(), 0u); // nothing recorded by the observer -} +} \ No newline at end of file diff --git a/test/test_dash_block_relay_dual_arm.cpp b/test/test_dash_block_relay_dual_arm.cpp index f8ef96c92..34b0abfd2 100644 --- a/test/test_dash_block_relay_dual_arm.cpp +++ b/test/test_dash_block_relay_dual_arm.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — WonBlock dual-arm delivery plan + reached-network verdict KATs. /// /// Exercises src/impl/dash/block_relay_dual_arm.hpp — the pure planner that @@ -261,4 +262,4 @@ TEST(DashDualArm, VerdictNotReachedWhenBothFail) EXPECT_FALSE(v.reached_network()); EXPECT_EQ(v.p2p_acks, 0u); EXPECT_FALSE(v.submitblock_ok); -} +} \ No newline at end of file diff --git a/test/test_dash_block_relay_plan.cpp b/test/test_dash_block_relay_plan.cpp index 01462af74..f01d06afa 100644 --- a/test/test_dash_block_relay_plan.cpp +++ b/test/test_dash_block_relay_plan.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — WonBlockRelay live-slots reply-path KATs. /// /// Exercises src/impl/dash/block_relay_plan.hpp — the planner that binds the @@ -216,4 +217,4 @@ TEST(DashRelayPlan, EndToEnd_AnnounceThenGetdataReturnsBlock) { EXPECT_EQ(parsed->m_block.m_version, blk.m_version); EXPECT_EQ(parsed->m_block.m_previous_block, blk.m_previous_block); EXPECT_EQ(parsed->m_block.m_nonce, blk.m_nonce); -} +} \ No newline at end of file diff --git a/test/test_dash_block_replay.cpp b/test/test_dash_block_replay.cpp index 37270599d..7192acb83 100644 --- a/test/test_dash_block_replay.cpp +++ b/test/test_dash_block_replay.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Block-replay (BIP 152 compact-block) reassembly tests for DASH (S5 slice). // // Exercises the vendored compact-block encoding ported in @@ -283,4 +284,4 @@ TEST(DashBlockReplay, BlockTransactionsRoundTrip) { ASSERT_TRUE(decoded.txn[i]); EXPECT_EQ(tx_hash(*decoded.txn[i]), tx_hash(*resp.txn[i])) << "txn mismatch at " << i; } -} +} \ No newline at end of file diff --git a/test/test_dash_broadcaster.cpp b/test/test_dash_broadcaster.cpp index b4d117aea..24a286503 100644 --- a/test/test_dash_broadcaster.cpp +++ b/test/test_dash_broadcaster.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — DashBroadcaster peer-pool + discovery scaffold KATs. /// /// Exercises src/impl/dash/broadcaster.hpp — the PURE peer-pool + discovery + @@ -322,4 +323,4 @@ TEST(DashBroadcaster, FanOutHookOnLiveSlotsOnly) hook_calls = 0; EXPECT_EQ(b.submit_block_raw_all(block), 0u); EXPECT_EQ(hook_calls, 0); -} +} \ No newline at end of file diff --git a/test/test_dash_broadcaster_full.cpp b/test/test_dash_broadcaster_full.cpp index 2ae3ef371..77817572f 100644 --- a/test/test_dash_broadcaster_full.cpp +++ b/test/test_dash_broadcaster_full.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — DashBroadcasterFull won-block KEYSTONE KATs (dual-path #83). /// /// Exercises src/impl/dash/broadcaster_full.hpp — the keystone that routes a @@ -284,4 +285,4 @@ TEST(DashBroadcasterFull, ThrowingRpcDoesNotMaskEmbeddedWin) EXPECT_TRUE(out.rpc_attempted); EXPECT_FALSE(out.rpc_submitted); // ARM B threw -> treated as no-ack EXPECT_TRUE(out.reached_network()); // P2P win not masked -} +} \ No newline at end of file diff --git a/test/test_dash_cb_payee.cpp b/test/test_dash_cb_payee.cpp index 80f645532..51f8a6855 100644 --- a/test/test_dash_cb_payee.cpp +++ b/test/test_dash_cb_payee.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase G3b regression KAT — bad-cb-payee / empty-payee normalization. /// /// Root cause (2026-06-27): on REAL testnet3 (fork-active) dashd surfaces the @@ -86,4 +87,4 @@ TEST(DashCbPayee, NonObjectEntryYieldsEmptyPayment) { PackedPayment pp = normalize_payment(entry); EXPECT_TRUE(pp.payee.empty()); EXPECT_EQ(pp.amount, 0u); -} +} \ No newline at end of file diff --git a/test/test_dash_coinbase_parity.cpp b/test/test_dash_coinbase_parity.cpp index 692707e84..77ed347ca 100644 --- a/test/test_dash_coinbase_parity.cpp +++ b/test/test_dash_coinbase_parity.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase G1 byte-parity — DASH coinbase/payee serialization conformance vs the /// canonical oracle frstrtr/p2pool-dash (older-than-v35). /// @@ -242,4 +243,4 @@ TEST(DashCoinbaseParity, V36DonationFloorOneSat) { uint64_t sum = 0; for (auto& o : outs) sum += o.amount; EXPECT_EQ(sum, subsidy); // invariant preserved -} +} \ No newline at end of file diff --git a/test/test_dash_config.cpp b/test/test_dash_config.cpp index 738d6aad1..1b4b3d273 100644 --- a/test/test_dash_config.cpp +++ b/test/test_dash_config.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — Dash coin/pool config types KATs /// /// Exercises src/impl/dash/config.hpp — the dash::PoolConfig / dash::CoinConfig @@ -112,4 +113,4 @@ TEST(DashConfig, NetServiceEndpointParse) NetService ep{std::string{"192.168.86.52"}, std::string{"19998"}}; EXPECT_EQ(ep.port(), 19998); EXPECT_EQ(ep.to_string(), std::string{"192.168.86.52:19998"}); -} +} \ No newline at end of file diff --git a/test/test_dash_conformance.cpp b/test/test_dash_conformance.cpp index ae6325a10..fa11e88e1 100644 --- a/test/test_dash_conformance.cpp +++ b/test/test_dash_conformance.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH V36 conformance — merkle-root-equality precondition (S6 slice). // // Before any share/block can be conformance-checked against DASH's own @@ -1484,4 +1485,4 @@ TEST(DashVersionGateThresholdSSOT, GatesUnchangedThroughNamedPath) { // 85% crossing floor (3-arg) — unchanged: 84% fails, 85% passes when active. EXPECT_FALSE(successor_switch_allowed({{36u, uint288(84u)}, {16u, uint288(16u)}}, 36u, /*crossing_active=*/true)); EXPECT_TRUE (successor_switch_allowed({{36u, uint288(85u)}, {16u, uint288(15u)}}, 36u, /*crossing_active=*/true)); -} +} \ No newline at end of file diff --git a/test/test_dash_difficulty_parity.cpp b/test/test_dash_difficulty_parity.cpp index 10828be0d..f04040997 100644 --- a/test/test_dash_difficulty_parity.cpp +++ b/test/test_dash_difficulty_parity.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH G1 difficulty / vardiff PARITY KAT. // // Pins the DASH sharechain difficulty floor and its per-share work accounting @@ -107,4 +108,4 @@ TEST(DashDifficultyParity, MainnetFloorBitsRoundtrip) uint256 decoded = chain::bits_to_target(bits); EXPECT_EQ(decoded, floor); // exact roundtrip at the standard floor EXPECT_EQ(bits >> 24, 0x1du); // 0xFFFF*2**208 -> exponent 0x1d (29 bytes) -} +} \ No newline at end of file diff --git a/test/test_dash_donation_combined.cpp b/test/test_dash_donation_combined.cpp index faae1f8bb..50edcec7e 100644 --- a/test/test_dash_donation_combined.cpp +++ b/test/test_dash_donation_combined.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase v36-migration-std — DASH unified v36 donation-P2SH standardization KATs. /// /// Closes the Bucket-2 gap (operator FLAG6, 2026-06-17 3-bucket rule): DASH was @@ -60,4 +61,4 @@ TEST(DashDonationCombined, V36SelectsCombinedP2SH) TEST(DashDonationCombined, ScriptsDiffer) { EXPECT_NE(dash::DONATION_SCRIPT, dash::COMBINED_DONATION_SCRIPT); -} +} \ No newline at end of file diff --git a/test/test_dash_embedded_gbt.cpp b/test/test_dash_embedded_gbt.cpp index 87e486594..b5e138fda 100644 --- a/test/test_dash_embedded_gbt.cpp +++ b/test/test_dash_embedded_gbt.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-TEMPLATE step 5 (S7 embedded_gbt capstone) — Dash embedded /// getblocktemplate bit-parity unit tests. /// @@ -554,4 +555,4 @@ TEST(DashEmbeddedGbt, G1GoldenVersionSeamEchoesInjectedVersion) { EXPECT_EQ(injected.m_mintime, baseline.m_mintime); EXPECT_EQ(injected.m_coinbase_value, baseline.m_coinbase_value); EXPECT_EQ(injected.m_payment_amount, baseline.m_payment_amount); -} +} \ No newline at end of file diff --git a/test/test_dash_embedded_relay_e2e.cpp b/test/test_dash_embedded_relay_e2e.cpp index 20d51fad2..6bb80d6ff 100644 --- a/test/test_dash_embedded_relay_e2e.cpp +++ b/test/test_dash_embedded_relay_e2e.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// test_dash_embedded_relay_e2e.cpp /// /// Phase S8 — EMBEDDED won-block relay END-TO-END KAT (won-block-reaches-network). @@ -244,4 +245,4 @@ TEST(DashEmbeddedRelayE2E, ByteParityIdenticalAcrossAllPeers) { auto served = bytes_of(message_block::make_raw(d)->m_data); EXPECT_EQ(served, h.won_wire); // every peer got identical bytes } -} +} \ No newline at end of file diff --git a/test/test_dash_g3_assembled.cpp b/test/test_dash_g3_assembled.cpp index 894d85ea2..c1226611f 100644 --- a/test/test_dash_g3_assembled.cpp +++ b/test/test_dash_g3_assembled.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase G3 ASSEMBLED — DASH per-coin block-production gate (integrator 2026-06-26). /// /// The other dash KATs pin each block-production PRIMITIVE in isolation: @@ -354,4 +355,4 @@ TEST(DashG3Assembled, NoPathAssembledBlockNotSilentlyDropped) { EXPECT_EQ(out.peers_reached, 0u); EXPECT_FALSE(out.rpc_attempted); EXPECT_FALSE(out.reached_network()); -} +} \ No newline at end of file diff --git a/test/test_dash_header_chain.cpp b/test/test_dash_header_chain.cpp index 2cedca090..0ac70350b 100644 --- a/test/test_dash_header_chain.cpp +++ b/test/test_dash_header_chain.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Known-answer tests for DASH consensus: DarkGravityWave v3 per-block retarget // (PR-0 foundation, S3 slice) and the SPV HeaderChain primitives. // @@ -221,4 +222,4 @@ TEST(DashDGWv3Kat, RealTestnet3Window1497944ReproducesNextBits) { EXPECT_EQ(bits, 0x1e00f256u) << "DGW-v3 over the real 1497920..1497943 window must reproduce the " "node-assigned bits of block 1497944"; -} +} \ No newline at end of file diff --git a/test/test_dash_job_notify_roundtrip.cpp b/test/test_dash_job_notify_roundtrip.cpp index d67386814..4e6a5bdce 100644 --- a/test/test_dash_job_notify_roundtrip.cpp +++ b/test/test_dash_job_notify_roundtrip.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH S8 STRATUM-BINDING contract KAT -- job-notify ROUND-TRIP leaf. // // The final leaf of the S8 stratum-binding suite. Where test_dash_stratum_binding @@ -212,4 +213,4 @@ TEST(DashJobNotifyRoundTrip, CanonicalRootGolden) "d445471556d06a5b2722c27f92498bf030117d756fd8fe7997d3732cf4df5e93"); EXPECT_EQ(root_for(E2_B).GetHex(), "7c81c0a061417d008d0ada06bfe98d69d82ea6561ec1c327f7fb34d63259772c"); -} +} \ No newline at end of file diff --git a/test/test_dash_mempool.cpp b/test/test_dash_mempool.cpp index d2885e9e7..6d7e93f7a 100644 --- a/test/test_dash_mempool.cpp +++ b/test/test_dash_mempool.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-MEMPOOL step 1+2 — Dash in-memory mempool unit tests /// /// Exercises the storage layer, UTXO-fee computation, LRU size-cap @@ -400,4 +401,4 @@ TEST(DashMempool, FeerateCompareIsDivisionFreeCrossMultiplyNotPreDividedDouble) const FeeKey lo{10000u, 250u, ta}; // 40 sat/byte, but smaller txid EXPECT_TRUE(hi < lo) << "higher feerate must precede regardless of txid"; EXPECT_FALSE(lo < hi); -} +} \ No newline at end of file diff --git a/test/test_dash_min_protocol_gate.cpp b/test/test_dash_min_protocol_gate.cpp index e29c52fbc..5d16478b0 100644 --- a/test/test_dash_min_protocol_gate.cpp +++ b/test/test_dash_min_protocol_gate.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // KAT for the DASH min-protocol-version ratchet gate (#643, option a). // // Pins the two invariants integrator required for the SAFE-ADDITIVE leaf: @@ -61,4 +62,4 @@ TEST(DashMinProtocolGate, RatchetIsParameterizedNotBaked) MinProtocolGate defaulted; EXPECT_TRUE(defaulted.accepts(1700u)); EXPECT_EQ(defaulted.min_version, 1700u); -} +} \ No newline at end of file diff --git a/test/test_dash_mn_state.cpp b/test/test_dash_mn_state.cpp index 3ab084133..c98f77630 100644 --- a/test/test_dash_mn_state.cpp +++ b/test/test_dash_mn_state.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-PAY (S7 mn_state_machine leaf) — Dash masternode state-machine /// unit tests. /// @@ -719,4 +720,4 @@ TEST(DashMnState, SyncValidityFromSmlIdempotentAndSmlOnly) { CSimplifiedMNList(std::vector{only}), 2450001); EXPECT_EQ(r2.sml_only, 1u); EXPECT_EQ(r2.matched, 0u); -} +} \ No newline at end of file diff --git a/test/test_dash_node.cpp b/test/test_dash_node.cpp index 667ebdca8..c59672b86 100644 --- a/test/test_dash_node.cpp +++ b/test/test_dash_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH S8 pool-node leaf 5 (FINAL) slice A — node.hpp skeleton KAT. // // Slice A is the class SKELETON + accessors only (reception/broadcast/think are @@ -205,4 +206,4 @@ TEST(DashNodeDispatch, NodeBridgeAliasBindsLegacyActual) static_assert(std::is_base_of_v, "Actual must derive from NodeImpl"); SUCCEED(); -} +} \ No newline at end of file diff --git a/test/test_dash_node_interface.cpp b/test/test_dash_node_interface.cpp index 8ea33a3a7..28f32ffab 100644 --- a/test/test_dash_node_interface.cpp +++ b/test/test_dash_node_interface.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — Dash coin-daemon node-interface seam KATs /// /// Exercises src/impl/dash/coin/node_interface.hpp — the dash::interfaces::Node @@ -137,4 +138,4 @@ TEST(DashNodeInterfaceKat, KnownTxsLookup) EXPECT_TRUE(node.known_txs.find(k) != node.known_txs.end()); } -} // namespace +} // namespace \ No newline at end of file diff --git a/test/test_dash_p2p_connection.cpp b/test/test_dash_p2p_connection.cpp index d8cb73962..7b89b8522 100644 --- a/test/test_dash_p2p_connection.cpp +++ b/test/test_dash_p2p_connection.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — Dash coin-daemon P2P connection KATs /// /// Exercises src/impl/dash/coin/p2p_connection.hpp — the per-peer @@ -147,4 +148,4 @@ TEST(DashP2PConnection, ConcurrentRequestsAreNotCrossWired) EXPECT_EQ(got_a.m_merkle_root, id_of(0xAA)); EXPECT_EQ(got_b.m_nonce, 200u); EXPECT_EQ(got_b.m_merkle_root, id_of(0xBB)); -} +} \ No newline at end of file diff --git a/test/test_dash_p2p_messages.cpp b/test/test_dash_p2p_messages.cpp index 153d0957a..f4f2de112 100644 --- a/test/test_dash_p2p_messages.cpp +++ b/test/test_dash_p2p_messages.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — Dash coin-daemon P2P wire-message KATs /// /// Exercises the Dash-specific messages in @@ -184,4 +185,4 @@ TEST(DashP2PMessages, CommandStringsPinned) { EXPECT_EQ(message_getmnlistd::make_raw(raw256_seq(0), raw256_seq(1))->m_command, "getmnlistd"); CSimplifiedMNListDiff d; EXPECT_EQ(message_mnlistdiff::make_raw(d)->m_command, "mnlistdiff"); -} +} \ No newline at end of file diff --git a/test/test_dash_p2p_node.cpp b/test/test_dash_p2p_node.cpp index 622fbc57d..cc3de7ec6 100644 --- a/test/test_dash_p2p_node.cpp +++ b/test/test_dash_p2p_node.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — Dash coin-daemon P2P node (socket-node skeleton) KATs /// /// Exercises src/impl/dash/coin/p2p_node.hpp — the socket-node lifecycle layer @@ -209,4 +210,4 @@ TEST(DashP2PNode, TornDownNodeDropsExchangeCallsAndTeardownIsIdempotent) [&](BlockHeaderType) { ++handler_calls; })); EXPECT_NO_THROW(node.deliver_header(id_of(1), BlockHeaderType{})); EXPECT_EQ(handler_calls, 0); -} +} \ No newline at end of file diff --git a/test/test_dash_peer.cpp b/test/test_dash_peer.cpp index 0c52bad61..95825671d 100644 --- a/test/test_dash_peer.cpp +++ b/test/test_dash_peer.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase S8 — Dash sharechain pool-node leaf 1: per-peer state (src/impl/dash/peer.hpp). /// /// dash::Peer is the analog of btc::Peer / dgb::Peer: the state a pool Node holds @@ -99,4 +100,4 @@ TEST(DashPeer, ConnectedAtMonotonicAcrossPeers) Peer a; Peer b; EXPECT_LE(a.m_connected_at, b.m_connected_at); -} +} \ No newline at end of file diff --git a/test/test_dash_poolnode_messages.cpp b/test/test_dash_poolnode_messages.cpp index 8d34f0464..dc4d30574 100644 --- a/test/test_dash_poolnode_messages.cpp +++ b/test/test_dash_poolnode_messages.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // KAT for the Dash sharechain pool-node wire layer (src/impl/dash/messages.hpp). // Proves each pool-node BEGIN_MESSAGE round-trips byte-for-byte and the type-list // instantiates — the btc/dgb/ltc analog ported namespace-only to dash. @@ -138,5 +139,4 @@ TEST(DashPoolNodeMessages, Handler_TypeList_Compiles) { // storage, which is defined out-of-line in the (not-yet-landed) node.cpp. using HandlerResult = Handler::result_t; EXPECT_GT(sizeof(HandlerResult), 0u); -} - +} \ No newline at end of file diff --git a/test/test_dash_quorum.cpp b/test/test_dash_quorum.cpp index 543f86214..2197eae22 100644 --- a/test/test_dash_quorum.cpp +++ b/test/test_dash_quorum.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-QUO — Dash LLMQ quorum-tail verification leaf unit tests /// /// Exercises the vendored CFinalCommitment / QuorumTail parser and the @@ -415,4 +416,4 @@ TEST(DashQuorum, ManagerReplaceStateWarmsActiveSet) { mgr.clear(); EXPECT_EQ(mgr.active_count(), 0u); EXPECT_TRUE(mgr.latest_cl_sigs().empty()); -} +} \ No newline at end of file diff --git a/test/test_dash_quorum_root.cpp b/test/test_dash_quorum_root.cpp index d806fc6da..30bcaeb3c 100644 --- a/test/test_dash_quorum_root.cpp +++ b/test/test_dash_quorum_root.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-TEMPLATE step 4c — Dash merkleRootQuorums computation leaf unit tests /// /// Exercises the vendored CalcCbTxMerkleRootQuorums mirror: @@ -331,4 +332,4 @@ TEST(DashQuorumRootKat, MixedRotatedAndNonRotatedFrozenGolden) // serialization changed; re-pin only after verifying intentional. EXPECT_EQ(to_hex_rev(root), "2cc59f74a7c40646968dafddcfba9759bc66a327c83695b304984f84dbeb0c37"); -} +} \ No newline at end of file diff --git a/test/test_dash_rpc_conf.cpp b/test/test_dash_rpc_conf.cpp index 477962273..ad5917ac9 100644 --- a/test/test_dash_rpc_conf.cpp +++ b/test/test_dash_rpc_conf.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH external-dashd RPC creds-resolution KAT (launcher slice 4). // // Exercises the dash.conf credential parser + endpoint-override + arm-gating @@ -124,4 +125,4 @@ TEST_F(DashRpcConf, MissingFileLeavesUnarmed) RpcConf c; EXPECT_FALSE(load_rpc_conf("/nonexistent/path/dash.conf.xyz", c)); EXPECT_FALSE(c.armed()); -} +} \ No newline at end of file diff --git a/test/test_dash_rpc_request.cpp b/test/test_dash_rpc_request.cpp index 08df4db6a..9bc5454ea 100644 --- a/test/test_dash_rpc_request.cpp +++ b/test/test_dash_rpc_request.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // --------------------------------------------------------------------------- // DASH launcher-slice-3 RPC request-shape regression guard. // @@ -98,4 +99,4 @@ TEST(DashRpcRequest, GenesisSelectorPicksByNetwork) { EXPECT_STREQ(dash_genesis_hash(false), DASH_GENESIS_MAIN); EXPECT_STREQ(dash_genesis_hash(true), DASH_GENESIS_TEST); -} +} \ No newline at end of file diff --git a/test/test_dash_share_hash_link.cpp b/test/test_dash_share_hash_link.cpp index 5cd4a3989..bfa1cda28 100644 --- a/test/test_dash_share_hash_link.cpp +++ b/test/test_dash_share_hash_link.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH share hash_link / gentx_hash byte-parity vs oracle (frstrtr/p2pool-dash). // // Pins the coinbase_payload encoding inside the gentx hash_link_data assembly. @@ -254,4 +255,4 @@ TEST(DashShareHashLink, ShareInitVerifyAppendsVarStrPayload) { EXPECT_EQ(hex_of(actual), hex_of(expected)) << "share_init_verify must append VarStr(coinbase_payload), not raw bytes"; EXPECT_NE(hex_of(actual), hex_of(buggy)); -} +} \ No newline at end of file diff --git a/test/test_dash_share_messages.cpp b/test/test_dash_share_messages.cpp index f8ab68fc5..2fab4f64d 100644 --- a/test/test_dash_share_messages.cpp +++ b/test/test_dash_share_messages.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -149,4 +150,4 @@ TEST(DashShareMessages, EmptyBlobIsAlwaysValid) auto err = dash::validate_message_data(empty); EXPECT_TRUE(err.empty()) << "Empty message_data must be valid (no messages): " << err; -} +} \ No newline at end of file diff --git a/test/test_dash_share_tracker.cpp b/test/test_dash_share_tracker.cpp index ef39d0fb2..eb1d71276 100644 --- a/test/test_dash_share_tracker.cpp +++ b/test/test_dash_share_tracker.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH S8 pool-node leaf 4 — share_tracker.hpp KAT. // // Exercises the consensus-bearing, PoW-independent core of the DASH ShareTracker @@ -176,4 +177,4 @@ TEST(DashShareTracker, DistinctScriptsSeparate) EXPECT_EQ(w.weights.size(), 2u); const uint288 sum = w.weights.at(script_a()) + w.weights.at(script_b()); EXPECT_EQ(w.total_weight, sum); -} +} \ No newline at end of file diff --git a/test/test_dash_simplifiedmns.cpp b/test/test_dash_simplifiedmns.cpp index 89e67002a..e8cd9bd6f 100644 --- a/test/test_dash_simplifiedmns.cpp +++ b/test/test_dash_simplifiedmns.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-SML step 1 — Dash SimplifiedMNList (DIP-0004) unit tests /// /// Exercises the vendored CSimplifiedMNListEntry / CSimplifiedMNList @@ -276,4 +277,4 @@ TEST(DashSimplifiedMNS, MerkleRootInvariantToInputOrder) { CSimplifiedMNList a(std::vector{e0, e1, e2, e3}); CSimplifiedMNList b(std::vector{e3, e2, e1, e0}); EXPECT_EQ(a.CalcMerkleRoot(), b.CalcMerkleRoot()); -} +} \ No newline at end of file diff --git a/test/test_dash_smldiff.cpp b/test/test_dash_smldiff.cpp index 6af00459a..7d3dc084b 100644 --- a/test/test_dash_smldiff.cpp +++ b/test/test_dash_smldiff.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-SML step 3 (S8.1) — Dash CSimplifiedMNListDiff wire KATs /// /// Exercises the vendored CSimplifiedMNListDiff + apply_diff() @@ -260,4 +261,4 @@ TEST(DashSMLDiff, ApplyEmptyDiffNoOp) { EXPECT_EQ(current.mnList.size(), before); EXPECT_EQ(current.mnList[0].proRegTxHash.data()[0], 0x03); EXPECT_EQ(current.mnList[1].proRegTxHash.data()[0], 0x07); -} +} \ No newline at end of file diff --git a/test/test_dash_stratum_binding.cpp b/test/test_dash_stratum_binding.cpp index 93ec604c8..aea0de8cf 100644 --- a/test/test_dash_stratum_binding.cpp +++ b/test/test_dash_stratum_binding.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH S8 STRATUM-BINDING contract KAT. // // Pins the get_work() -> stratum job binding contract: the extranonce2 @@ -168,4 +169,4 @@ TEST(DashStratumBinding, GoldenLeafHashes) "9bdc1a3b7b8600535e99c5298b6cb50fde48bd1b20a1ad6883abfbb2799b1b0e"); EXPECT_EQ(hash_of(reassemble(lay, std::span(E2_B, 8))).GetHex(), "a0acea5d125dd3452a24dd84c0d1245450dd237cfe0bc0170d4381195e5f8061"); -} +} \ No newline at end of file diff --git a/test/test_dash_subsidy.cpp b/test/test_dash_subsidy.cpp index 2d6623d34..126a93e3f 100644 --- a/test/test_dash_subsidy.cpp +++ b/test/test_dash_subsidy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase C-TEMPLATE step 1 — Dash subsidy formula unit tests /// /// Validates compute_dash_block_reward_post_v20 + compute_dash_mn_payment_post_v20 @@ -132,4 +133,4 @@ TEST(DashSubsidy, PlatformReward28125PercentOfBlockReward) int64_t expected_exact = (r * 9) / 32; EXPECT_LE(std::abs(p - expected_exact), 1LL) << "platform should match 9/32 of block_reward within int-truncation"; -} +} \ No newline at end of file diff --git a/test/test_dash_version_activation_latch.cpp b/test/test_dash_version_activation_latch.cpp index 5b3588d64..501a3e75d 100644 --- a/test/test_dash_version_activation_latch.cpp +++ b/test/test_dash_version_activation_latch.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase v36-migration-std — DASH Component A persisted activation LATCH KATs. /// /// Exercises src/impl/dash/version_activation_latch.hpp — the persisted @@ -114,4 +115,4 @@ TEST(DashVersionActivationLatch, DefaultSpanIsTwoChainLen) { ActivationLatch l; EXPECT_EQ(l.confirm_span, 2ull * dash::SharechainConfig::CHAIN_LENGTH); -} +} \ No newline at end of file diff --git a/test/test_dash_work_job_targets.cpp b/test/test_dash_work_job_targets.cpp index 201314dc8..5e126a588 100644 --- a/test/test_dash_work_job_targets.cpp +++ b/test/test_dash_work_job_targets.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH S8 get_work() JOB-TARGET assembly KAT. // // Pins dash::stratum::{modulate_desired_pseudoshare_target, clip_to_sane, @@ -117,4 +118,4 @@ TEST(DashWorkJobTargets, AssembleSuppliedClippedAndFloored) WorkJobTargets out = assemble_work_job_targets(in); EXPECT_EQ(out.share_target.GetHex(), SMAX_HEX); EXPECT_EQ(out.min_share_target.GetHex(), SMAX_HEX); -} +} \ No newline at end of file diff --git a/test/test_dash_work_target.cpp b/test/test_dash_work_target.cpp index 1b7c5cd7d..bc1c81f6a 100644 --- a/test/test_dash_work_target.cpp +++ b/test/test_dash_work_target.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // DASH S8 work-target MODULATION KAT. // // Pins dash::stratum::modulate_desired_share_target (+ its two caps) to @@ -140,4 +141,4 @@ TEST(DashWorkTarget, ModulateUnconstrainedIsMax) { WorkTargetInputs in; // all defaults: no hashrate, no gate EXPECT_EQ(modulate_desired_share_target(in).GetHex(), MAX_TARGET_HEX); -} +} \ No newline at end of file diff --git a/test/test_dash_x11_kat.cpp b/test/test_dash_x11_kat.cpp index 16dc0a534..7caa6007f 100644 --- a/test/test_dash_x11_kat.cpp +++ b/test/test_dash_x11_kat.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Known-answer test for the DASH X11 PoW primitive (PR-0 foundation, S2 slice). // // Vector: the DASH mainnet genesis block. Hashing its 80-byte header with X11 @@ -165,4 +166,4 @@ TEST(DashX11Kat, Testnet3RawHeadersReproduceBlockHash) { EXPECT_EQ(pow.GetHex(), v.expected_hash) << "X11 byte-parity mismatch at testnet3 height " << v.height; } -} +} \ No newline at end of file diff --git a/test/test_decay_pplns.cpp b/test/test_decay_pplns.cpp index aabd59ed7..8ab629526 100644 --- a/test/test_decay_pplns.cpp +++ b/test/test_decay_pplns.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -243,4 +244,4 @@ int main(int argc, char** argv) { ::testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); -} +} \ No newline at end of file diff --git a/test/test_dgb_coinbase_value.cpp b/test/test_dgb_coinbase_value.cpp index ed26630ff..87a8e59b7 100644 --- a/test/test_dgb_coinbase_value.cpp +++ b/test/test_dgb_coinbase_value.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Forward-only TODO (integrator 2026-06-18): wire CoinParams::subsidy_func into // the embedded coinbase builder + a 4-era boundary conformance test, with the // external-daemon GBT fallback preserved. @@ -87,4 +88,4 @@ TEST(DgbCoinbaseValue, NoGbtDerivesEmbedded) { TEST(DgbCoinbaseValue, UnsetSubsidyFuncThrows) { core::SubsidyFunc empty; EXPECT_THROW(dgb::coin::embedded_coinbase_value(empty, 400000, 0), std::logic_error); -} +} \ No newline at end of file diff --git a/test/test_dgb_subsidy.cpp b/test/test_dgb_subsidy.cpp index 2ed07605e..218211383 100644 --- a/test/test_dgb_subsidy.cpp +++ b/test/test_dgb_subsidy.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Regression test: DGB block subsidy vs the coin's OWN canonical oracle, // p2pool-dgb-scrypt (bitcoin/networks/digibyte.py :: get_subsidy). // @@ -59,4 +60,4 @@ TEST(DgbSubsidy, NeverBelowCoinFloor) { EXPECT_GE(dgb::CoinParams::subsidy(height), 1000000ULL) << "subsidy floor breached at height " << height; } -} +} \ No newline at end of file diff --git a/test/test_doge_chain.cpp b/test/test_doge_chain.cpp index c69ebfdad..eb51f6e03 100644 --- a/test/test_doge_chain.cpp +++ b/test/test_doge_chain.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// DOGE chain unit tests — embedded SPV node components /// /// Tests: @@ -687,4 +688,4 @@ TEST(MersenneTwisterTest, ResultInRange) { TEST(MersenneTwisterTest, SingleValueRange) { int r = doge_mt_uniform_int(42, 5, 5); EXPECT_EQ(r, 5); -} +} \ No newline at end of file diff --git a/test/test_hardening.cpp b/test/test_hardening.cpp index ed57d4cc4..5fa86677b 100644 --- a/test/test_hardening.cpp +++ b/test/test_hardening.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Regression tests for the hardening changes introduced in * "Harden coin RPC/P2P safety checks" (commit 2e7fadba). @@ -303,4 +304,4 @@ TEST(ReplyMatcherTimeout, ResponseBeforeTimeoutCancelsTimer) ioc.run_for(std::chrono::milliseconds(100)); EXPECT_EQ(m.m_watchers.size(), 0u); -} +} \ No newline at end of file diff --git a/test/test_hash_link.cpp b/test/test_hash_link.cpp index 4e75cedfc..794ad997f 100644 --- a/test/test_hash_link.cpp +++ b/test/test_hash_link.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Unit tests for the hash_link round-trip: * prefix_to_hash_link(prefix, const_ending) → hash_link @@ -431,4 +432,4 @@ TEST(HashLink, ProductionPathCoinbase) { // Hash_link round-trip test EXPECT_TRUE(verify_hash_link_roundtrip(coinbase_bytes, split, gentx_before_refhash)) << "Production-path coinbase hash_link round-trip failed"; -} +} \ No newline at end of file diff --git a/test/test_header_chain.cpp b/test/test_header_chain.cpp index c49f63215..d009bb680 100644 --- a/test/test_header_chain.cpp +++ b/test/test_header_chain.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 1 — HeaderChain unit tests /// /// Tests the LTC header chain implementation: @@ -620,4 +621,4 @@ TEST_F(HeaderChainTest, PeerTipHeightIsAtomic) { // No crash, no data race — the final value is one of the written values // (no specific ordering guarantee with relaxed atomics) -} +} \ No newline at end of file diff --git a/test/test_mempool.cpp b/test/test_mempool.cpp index 189cd939f..bdc75f479 100644 --- a/test/test_mempool.cpp +++ b/test/test_mempool.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 2 — Mempool unit tests /// /// Tests the LTC mempool implementation: @@ -433,4 +434,4 @@ TEST(MempoolTest, ConcurrentAddRemove) { // Pool should be in a consistent state (no crash, no invariant violation) EXPECT_LE(pool.size(), 50u); EXPECT_LE(pool.byte_size(), 50u * 200u); // rough upper bound -} +} \ No newline at end of file diff --git a/test/test_multiaddress_pplns.cpp b/test/test_multiaddress_pplns.cpp index e2801607b..9cd05365d 100644 --- a/test/test_multiaddress_pplns.cpp +++ b/test/test_multiaddress_pplns.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_multiaddress_pplns.cpp — Tests for multiaddress coinbase building // and PPLNS consensus validation across parent and merged chains. // @@ -1228,4 +1229,4 @@ TEST_F(MultiaddressCoinbaseTest, HeightEncodingLargeValue) EXPECT_EQ(raw[pos], 3u) << "Height 100000 should need 3 bytes"; uint32_t h = raw[pos + 1] | (raw[pos + 2] << 8) | (raw[pos + 3] << 16); EXPECT_EQ(h, 100000u); -} +} \ No newline at end of file diff --git a/test/test_mweb_builder.cpp b/test/test_mweb_builder.cpp index 4526c84e0..6fe59e66c 100644 --- a/test/test_mweb_builder.cpp +++ b/test/test_mweb_builder.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Unit tests for the MWEB builder (mweb_builder.hpp). * @@ -510,4 +511,4 @@ TEST(MWEBBuilder, Blake3HashDifferentData) { EXPECT_FALSE(h1.IsNull()); EXPECT_FALSE(h2.IsNull()); EXPECT_NE(h1, h2); -} +} \ No newline at end of file diff --git a/test/test_phase0_live.cpp b/test/test_phase0_live.cpp index 98801be24..332a11a98 100644 --- a/test/test_phase0_live.cpp +++ b/test/test_phase0_live.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 0 — Live daemon integration tests /// /// Connects to a real Litecoin testnet daemon P2P port and verifies @@ -258,4 +259,4 @@ TEST_F(Phase0LiveTest, BroadcasterConnectAndReceiveEvents) << " peers=" << peers_before_stop << (total == 0 ? " (quiet testnet)" : "") << std::endl; -} +} \ No newline at end of file diff --git a/test/test_phase1_live.cpp b/test/test_phase1_live.cpp index 837c90810..ef43d515b 100644 --- a/test/test_phase1_live.cpp +++ b/test/test_phase1_live.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 1 — Live daemon integration tests /// /// Connects to a real Litecoin testnet daemon P2P port and verifies @@ -326,4 +327,4 @@ TEST_F(Phase1LiveTest, BroadcasterFeedsHeaderChain) EXPECT_GE(peers, 1) << "Broadcaster should have at least one peer"; -} +} \ No newline at end of file diff --git a/test/test_phase2_live.cpp b/test/test_phase2_live.cpp index 32b843d14..9a0a1ddd7 100644 --- a/test/test_phase2_live.cpp +++ b/test/test_phase2_live.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 2 — Live daemon integration tests /// /// Connects to a real Litecoin testnet daemon P2P port and verifies @@ -363,4 +364,4 @@ TEST_F(Phase2LiveTest, BroadcasterFeedsMempool) // Byte accounting must be consistent EXPECT_EQ(pool.byte_size() > 0 || pool.size() == 0, true); -} +} \ No newline at end of file diff --git a/test/test_phase3_live.cpp b/test/test_phase3_live.cpp index 5b9c09847..1b0aa88c8 100644 --- a/test/test_phase3_live.cpp +++ b/test/test_phase3_live.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 3 — Live daemon integration tests /// /// Connects to a real LTC testnet P2P port, syncs headers + mempool, then @@ -440,4 +441,4 @@ TEST_F(Phase3LiveTest, SubsidyAtSyncedHeight) // For the unit test: our computed value must equal the LTC subsidy schedule. EXPECT_EQ(static_cast(cv), expected_subsidy) << "coinbasevalue should equal pure block subsidy at height " << next_h; -} +} \ No newline at end of file diff --git a/test/test_phase4_embedded.cpp b/test/test_phase4_embedded.cpp index cac55ba2d..a0af7fa30 100644 --- a/test/test_phase4_embedded.cpp +++ b/test/test_phase4_embedded.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 4 — Embedded Coin Node unit tests /// /// Tests the EmbeddedCoinNode / CoinNodeInterface wiring for the @@ -343,4 +344,4 @@ TEST(Phase4MiningInterfaceTest, RefreshWorkWithNoNodeIsNoop) { EXPECT_NO_THROW(mi.refresh_work()); auto tmpl = mi.get_current_work_template(); EXPECT_TRUE(tmpl.is_null() || tmpl.empty()); -} +} \ No newline at end of file diff --git a/test/test_phase4_live.cpp b/test/test_phase4_live.cpp index 8dbd02b91..7229b68f1 100644 --- a/test/test_phase4_live.cpp +++ b/test/test_phase4_live.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 4 — Live daemon-less integration tests /// /// Verifies the full embedded-node pipeline end-to-end against a live LTC @@ -383,4 +384,4 @@ TEST_F(Phase4LiveTest, BlockRelHeightViaSyncedChain) uint256 unknown; unknown.SetHex("deadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef"); EXPECT_EQ(block_rel_height(unknown), 0); -} +} \ No newline at end of file diff --git a/test/test_pplns_consensus.cpp b/test/test_pplns_consensus.cpp index e53c2bf97..63cedc657 100644 --- a/test/test_pplns_consensus.cpp +++ b/test/test_pplns_consensus.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_pplns_consensus.cpp — Tests for the PPLNS consensus fixes. // // Covers: @@ -708,4 +709,4 @@ int main(int argc, char** argv) { ::testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); -} +} \ No newline at end of file diff --git a/test/test_pplns_stress.cpp b/test/test_pplns_stress.cpp index f7146d80b..7043985e1 100644 --- a/test/test_pplns_stress.cpp +++ b/test/test_pplns_stress.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_pplns_stress.cpp — Stress tests for PPLNS consensus verification // on both parent (LTC) and merged (DOGE) chains. // @@ -878,4 +879,4 @@ TEST_F(PPLNSStressTest, EndToEnd_PayoutHashToBlock_ParentAndMerged) if (s == donation_vec) { doge_has_donation = true; EXPECT_GE(v, 1u); } EXPECT_TRUE(ltc_has_donation) << "LTC block must have donation output"; EXPECT_TRUE(doge_has_donation) << "DOGE block must have donation output"; -} +} \ No newline at end of file diff --git a/test/test_redistribute.cpp b/test/test_redistribute.cpp index 5faed904e..c113f6082 100644 --- a/test/test_redistribute.cpp +++ b/test/test_redistribute.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -219,4 +220,4 @@ TEST(RedistributeV2, ThresholdInverseLuck) double weight_a = 1.0 / std::max(0.01, 0.001); double weight_b = 1.0 / std::max(0.05, 0.001); EXPECT_NEAR(weight_a / weight_b, 5.0, 0.01); -} +} \ No newline at end of file diff --git a/test/test_redistribute_address.cpp b/test/test_redistribute_address.cpp index b66f07cf8..8597408c2 100644 --- a/test/test_redistribute_address.cpp +++ b/test/test_redistribute_address.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Unit tests for redistribute and address-conversion features. * @@ -287,4 +288,4 @@ TEST(AddressConversionCase4, ShortOrMalformedScriptNotExtracted) short_script[1] == 0xa9 && short_script[2] == 0x14); EXPECT_FALSE(valid); -} +} \ No newline at end of file diff --git a/test/test_share_messages.cpp b/test/test_share_messages.cpp index e460cd70c..89caf2fbc 100644 --- a/test/test_share_messages.cpp +++ b/test/test_share_messages.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include @@ -149,4 +150,4 @@ TEST(ShareMessages, EmptyBlobIsAlwaysValid) auto err = ltc::validate_message_data(empty); EXPECT_TRUE(err.empty()) << "Empty message_data must be valid (no messages): " << err; -} +} \ No newline at end of file diff --git a/test/test_stratum_extensions.cpp b/test/test_stratum_extensions.cpp index 78ab97a89..4f4f5c69e 100644 --- a/test/test_stratum_extensions.cpp +++ b/test/test_stratum_extensions.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Tests for Stratum protocol extensions: * 1. mining.configure — BIP 310 version-rolling + subscribe-extranonce @@ -723,4 +724,4 @@ TEST(StratumSuggestDifficulty, Sha256dRoundTripIsIdentity) EXPECT_DOUBLE_EQ(recovered, internal); // A SHA256d wire suggestion is NOT collapsed by a stray 65536 divisor. EXPECT_DOUBLE_EQ(wire, 0.0005); -} +} \ No newline at end of file diff --git a/test/test_template_builder.cpp b/test/test_template_builder.cpp index ed68222e0..42f8ddaf5 100644 --- a/test/test_template_builder.cpp +++ b/test/test_template_builder.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /// Phase 3 — TemplateBuilder unit tests /// /// Tests the LTC TemplateBuilder, subsidy schedule, Merkle tree, and @@ -492,4 +493,4 @@ TEST(CoinNodeInterfaceTest, EmbeddedNodeIsPolymorphic) { // Chain with only genesis is not synced — getwork() throws the sync gate EXPECT_THROW(iface->getwork(), std::runtime_error); EXPECT_FALSE(iface->is_synced()); -} +} \ No newline at end of file diff --git a/test/test_threading.cpp b/test/test_threading.cpp index c404fac72..14606352c 100644 --- a/test/test_threading.cpp +++ b/test/test_threading.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later /** * Threading architecture regression tests. * @@ -494,4 +495,4 @@ TEST(VerifyShareThreading, Phase2SkipsNullHashShares) EXPECT_FALSE(share.hash.IsNull()) << "Phase 2 emitted a share with null hash (index=" << share.index << ")"; } -} +} \ No newline at end of file diff --git a/test/test_utxo.cpp b/test/test_utxo.cpp index d79dc4b2b..ff320fca4 100644 --- a/test/test_utxo.cpp +++ b/test/test_utxo.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include #include #include @@ -204,4 +205,4 @@ TEST(UTXOTest, DisconnectFromUndo) { EXPECT_FALSE(cache.have_coin(added1)); EXPECT_FALSE(cache.have_coin(added2)); -} +} \ No newline at end of file diff --git a/test/test_v36_cross_impl_refhash.cpp b/test/test_v36_cross_impl_refhash.cpp index e98e76c03..f59093559 100644 --- a/test/test_v36_cross_impl_refhash.cpp +++ b/test/test_v36_cross_impl_refhash.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_v36_cross_impl_refhash.cpp — Cross-implementation ref_hash + gentx_hash test. // // Computes V36 ref_stream → ref_hash → coinbase → gentx_hash using the same @@ -575,4 +576,4 @@ TEST(V36CrossImplRefHash, EdgeCase_GenesisShare) ASSERT_EQ(result.sorted_outputs.size(), 1u); EXPECT_EQ(result.sorted_outputs[0].second, 999999999u); EXPECT_EQ(result.donation_amount, 1u); -} +} \ No newline at end of file diff --git a/test/test_v36_script_sorting.cpp b/test/test_v36_script_sorting.cpp index 402824a25..163567bd5 100644 --- a/test/test_v36_script_sorting.cpp +++ b/test/test_v36_script_sorting.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_v36_script_sorting.cpp — Cross-implementation V36 output sorting tests. // // V36 consensus: PPLNS outputs are sorted by (amount, script_bytes) ascending. @@ -331,4 +332,4 @@ TEST(V36ScriptSorting, MergedPayoutHashFormat) EXPECT_LT(pos_aa, pos_bb) << "0xaa script hex must appear before 0xbb"; EXPECT_NE(payload.find("T:5500"), std::string::npos); EXPECT_NE(payload.find("D:500"), std::string::npos); -} +} \ No newline at end of file diff --git a/test/test_web_honesty_regression.cpp b/test/test_web_honesty_regression.cpp index 15d3813a5..54dacb45f 100644 --- a/test/test_web_honesty_regression.cpp +++ b/test/test_web_honesty_regression.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // Web honesty-regression KAT (SAFE-ADDITIVE characterization test). // // Charter: "A dashboard must never lie about prod health." (founding bug @@ -573,4 +574,4 @@ TEST(WebHonestyRegression, PatronSendmanySelfLabelsAsStubNeverFabricatesPayouts) << "never label-as-stub while surfacing payout splits -- silent lie"; EXPECT_EQ(p.value("total", std::string{}), "12.5") << "the echoed total must be the operator-supplied value, not invented"; -} +} \ No newline at end of file diff --git a/test/test_weights.cpp b/test/test_weights.cpp index 3cbaae3e0..008d7468f 100644 --- a/test/test_weights.cpp +++ b/test/test_weights.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_weights.cpp — Unit tests for PPLNS weight computation // // Tests the WeightsSkipList (O(log n) cumulative weights) and the @@ -241,4 +242,4 @@ TEST(DecayedCache, SameQueryReturnsCachedResult) { EXPECT_EQ(combined_12.total_weight, combined_21.total_weight); EXPECT_EQ(combined_12.total_donation_weight, combined_21.total_donation_weight); EXPECT_EQ(combined_12.weights[{0xAA}], combined_21.weights[{0xAA}]); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/ApiClient.cpp b/ui/c2pool-qt/src/ApiClient.cpp index a92fab9a0..1b5bb4cd5 100644 --- a/ui/c2pool-qt/src/ApiClient.cpp +++ b/ui/c2pool-qt/src/ApiClient.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "ApiClient.hpp" #include @@ -141,4 +142,4 @@ void ApiClient::download(const QString& path, const QString& outputPath, TextSuc onSuccess(QString("Saved %1 bytes to %2").arg(payload.size()).arg(outputPath)); }); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/ApiClient.hpp b/ui/c2pool-qt/src/ApiClient.hpp index f3f38ba81..7488983e7 100644 --- a/ui/c2pool-qt/src/ApiClient.hpp +++ b/ui/c2pool-qt/src/ApiClient.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -34,4 +35,4 @@ class ApiClient : public QObject QNetworkAccessManager manager_; QString baseUrl_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/MainWindow.cpp b/ui/c2pool-qt/src/MainWindow.cpp index 94d17681b..7ac25db4a 100644 --- a/ui/c2pool-qt/src/MainWindow.cpp +++ b/ui/c2pool-qt/src/MainWindow.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "MainWindow.hpp" #include @@ -374,4 +375,4 @@ void MainWindow::refreshCurrentPage() default: break; } -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/MainWindow.hpp b/ui/c2pool-qt/src/MainWindow.hpp index 0be443f2e..a4e0c1d2e 100644 --- a/ui/c2pool-qt/src/MainWindow.hpp +++ b/ui/c2pool-qt/src/MainWindow.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "ApiClient.hpp" @@ -72,4 +73,4 @@ class MainWindow : public QMainWindow QTimer refreshTimer_; bool lastApiOnline_{false}; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageEmbedded.cpp b/ui/c2pool-qt/src/PageEmbedded.cpp index 09ad21470..9c7bced22 100644 --- a/ui/c2pool-qt/src/PageEmbedded.cpp +++ b/ui/c2pool-qt/src/PageEmbedded.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PageEmbedded.hpp" #include @@ -144,4 +145,4 @@ void PageEmbedded::keyPressEvent(QKeyEvent* ev) return; } QWidget::keyPressEvent(ev); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageEmbedded.hpp b/ui/c2pool-qt/src/PageEmbedded.hpp index a611ff9c1..0155feaac 100644 --- a/ui/c2pool-qt/src/PageEmbedded.hpp +++ b/ui/c2pool-qt/src/PageEmbedded.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // PageEmbedded — generic QWebEngineView host. // // One C++ class serves every embedded-web page; configuration differs @@ -79,4 +80,4 @@ class PageEmbedded : public QWidget { Config cfg_; QWebEngineView* view_ = nullptr; QWebChannel* channel_ = nullptr; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageLaunch.cpp b/ui/c2pool-qt/src/PageLaunch.cpp index deeebdf15..813245fb3 100644 --- a/ui/c2pool-qt/src/PageLaunch.cpp +++ b/ui/c2pool-qt/src/PageLaunch.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PageLaunch.hpp" #include "SettingsStore.hpp" @@ -819,4 +820,4 @@ void PageLaunch::loadSettings() onBuildPreview(); emitApiBaseUrlChanged(); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageLaunch.hpp b/ui/c2pool-qt/src/PageLaunch.hpp index 0bc2bde97..fc9fb102c 100644 --- a/ui/c2pool-qt/src/PageLaunch.hpp +++ b/ui/c2pool-qt/src/PageLaunch.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include @@ -142,4 +143,4 @@ private slots: QPushButton* launchBtn_; QPushButton* stopBtn_; QPushButton* restartBtn_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageLogs.cpp b/ui/c2pool-qt/src/PageLogs.cpp index fd34b043e..358ec46a4 100644 --- a/ui/c2pool-qt/src/PageLogs.cpp +++ b/ui/c2pool-qt/src/PageLogs.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PageLogs.hpp" #include @@ -108,4 +109,4 @@ void PageLogs::refresh(ApiClient* api) logView_->setPlainText("Failed to load log feed: " + err); } ); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageLogs.hpp b/ui/c2pool-qt/src/PageLogs.hpp index 55a3d43fc..1fe06eda2 100644 --- a/ui/c2pool-qt/src/PageLogs.hpp +++ b/ui/c2pool-qt/src/PageLogs.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "ApiClient.hpp" @@ -24,4 +25,4 @@ class PageLogs : public QWidget QPushButton* exportButton_; QPlainTextEdit* logView_; ApiClient* api_{nullptr}; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageMining.cpp b/ui/c2pool-qt/src/PageMining.cpp index 16e4b3623..5d6ea97fe 100644 --- a/ui/c2pool-qt/src/PageMining.cpp +++ b/ui/c2pool-qt/src/PageMining.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PageMining.hpp" #include "PageEmbedded.hpp" @@ -208,4 +209,4 @@ void PageMining::onUnbanMiner() return; } invokeControl(api_, QString("/control/mining/unban?target=%1").arg(target), "Miner unbanned"); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageMining.hpp b/ui/c2pool-qt/src/PageMining.hpp index aa43ed1ae..33119a7fa 100644 --- a/ui/c2pool-qt/src/PageMining.hpp +++ b/ui/c2pool-qt/src/PageMining.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "ApiClient.hpp" @@ -64,4 +65,4 @@ private slots: /** Embedded pplns-embed.html host — null when no bridges were * supplied (e.g. tests that don't wire the JS surface). */ PageEmbedded* pplnsEmbed_{nullptr}; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageOverview.cpp b/ui/c2pool-qt/src/PageOverview.cpp index b6c6e0aa3..b9b81f93a 100644 --- a/ui/c2pool-qt/src/PageOverview.cpp +++ b/ui/c2pool-qt/src/PageOverview.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PageOverview.hpp" #include @@ -106,4 +107,4 @@ void PageOverview::refresh(ApiClient* api) }, [](const QString&) { } ); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageOverview.hpp b/ui/c2pool-qt/src/PageOverview.hpp index 31e2e86a6..04cc0684a 100644 --- a/ui/c2pool-qt/src/PageOverview.hpp +++ b/ui/c2pool-qt/src/PageOverview.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #pragma once #include "ApiClient.hpp" @@ -23,4 +24,4 @@ class PageOverview : public QWidget QLabel* uniqueMinersValue_; QLabel* peersValue_; QLabel* statusValue_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageSettings.cpp b/ui/c2pool-qt/src/PageSettings.cpp index ad3af2ed4..36abdd384 100644 --- a/ui/c2pool-qt/src/PageSettings.cpp +++ b/ui/c2pool-qt/src/PageSettings.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PageSettings.hpp" #include "SettingsStore.hpp" @@ -326,4 +327,4 @@ QString PageSettings::keychainBackendLabel() #else return QObject::tr("QSettings fallback (no keychain)"); #endif -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/PageSettings.hpp b/ui/c2pool-qt/src/PageSettings.hpp index 9ae207449..ef4f60f30 100644 --- a/ui/c2pool-qt/src/PageSettings.hpp +++ b/ui/c2pool-qt/src/PageSettings.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // PageSettings — dedicated settings tab per §9 of // c2pool-qt-desktop-settings-module.md. // @@ -79,4 +80,4 @@ private slots: QLabel* aboutVersion_; QLabel* aboutConfigPath_; QLabel* aboutKeychain_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/SettingsStore.cpp b/ui/c2pool-qt/src/SettingsStore.cpp index 25ee5114d..0140b14aa 100644 --- a/ui/c2pool-qt/src/SettingsStore.cpp +++ b/ui/c2pool-qt/src/SettingsStore.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "SettingsStore.hpp" #include @@ -459,4 +460,4 @@ bool SettingsStore::importFromJson(const QByteArray& doc, QString* errorOut) emit changed(key); } return true; -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/SettingsStore.hpp b/ui/c2pool-qt/src/SettingsStore.hpp index 188b579f7..92e1d16d2 100644 --- a/ui/c2pool-qt/src/SettingsStore.hpp +++ b/ui/c2pool-qt/src/SettingsStore.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // SettingsStore — typed façade over QSettings (+ QKeychain in step 4). // // Public interface per @@ -118,4 +119,4 @@ class SettingsStore : public QObject { QString profileLaunchPath(const QString& profile, const QString& key) const; QString secretsKey(const QString& profile, const QString& key) const; void migrateV1ToV2(); -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/CoinBridge.cpp b/ui/c2pool-qt/src/bridges/CoinBridge.cpp index 01a50a4a3..aea0a4fb3 100644 --- a/ui/c2pool-qt/src/bridges/CoinBridge.cpp +++ b/ui/c2pool-qt/src/bridges/CoinBridge.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "CoinBridge.hpp" #include "../SettingsStore.hpp" @@ -140,4 +141,4 @@ QJsonObject CoinBridge::buildDescriptor(const QString& chain, bool testnet) // the shape stable. d.insert(QStringLiteral("mergedChains"), QJsonArray{}); return d; -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/CoinBridge.hpp b/ui/c2pool-qt/src/bridges/CoinBridge.hpp index 17ffd9c9d..88f15754c 100644 --- a/ui/c2pool-qt/src/bridges/CoinBridge.hpp +++ b/ui/c2pool-qt/src/bridges/CoinBridge.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // CoinBridge — exposes a CoinDescriptor-shaped JSON object to JS over // QtWebChannel so the embedded Explorer / PPLNS View bundles pull // coin params from c2pool authoritatively instead of reading @@ -46,4 +47,4 @@ class CoinBridge : public QObject { static QJsonObject buildDescriptor(const QString& chain, bool testnet); SettingsStore* settings_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/PplnsBridge.cpp b/ui/c2pool-qt/src/bridges/PplnsBridge.cpp index ec48924f0..4f67d1e17 100644 --- a/ui/c2pool-qt/src/bridges/PplnsBridge.cpp +++ b/ui/c2pool-qt/src/bridges/PplnsBridge.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "PplnsBridge.hpp" #include "ApiClient.hpp" @@ -134,4 +135,4 @@ QJsonObject PplnsBridge::buildTransportError(const QString& message, if (httpStatus > 0) err.insert(QStringLiteral("status"), httpStatus); if (!url.isEmpty()) err.insert(QStringLiteral("url"), url); return err; -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/PplnsBridge.hpp b/ui/c2pool-qt/src/bridges/PplnsBridge.hpp index 21970b8c3..e3cca5b31 100644 --- a/ui/c2pool-qt/src/bridges/PplnsBridge.hpp +++ b/ui/c2pool-qt/src/bridges/PplnsBridge.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // PplnsBridge — QtWebChannel transport for the embedded JS PPLNS View // bundle. Mirrors SharechainBridge, but scoped to the two PPLNS-specific // Transport operations (spec §4.2) + cancelRequest. @@ -55,4 +56,4 @@ private slots: ApiClient* api_; QNetworkAccessManager* nam_; QHash pending_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/SettingsBridge.cpp b/ui/c2pool-qt/src/bridges/SettingsBridge.cpp index 8b41b519f..f8baf3924 100644 --- a/ui/c2pool-qt/src/bridges/SettingsBridge.cpp +++ b/ui/c2pool-qt/src/bridges/SettingsBridge.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "SettingsBridge.hpp" #include "../SettingsStore.hpp" @@ -91,4 +92,4 @@ QString SettingsBridge::toStorePath(const QString& jsKey) QString SettingsBridge::toJsKey(const QString& storePath) { return QString(storePath).replace(QLatin1Char('/'), QLatin1Char('.')); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/SettingsBridge.hpp b/ui/c2pool-qt/src/bridges/SettingsBridge.hpp index 46f2b1210..93174b12b 100644 --- a/ui/c2pool-qt/src/bridges/SettingsBridge.hpp +++ b/ui/c2pool-qt/src/bridges/SettingsBridge.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // SettingsBridge — exposes a subset of SettingsStore to JS over // QtWebChannel so the embedded Explorer / PPLNS View bundles (and // their plugins) can persist view state into the same native @@ -56,4 +57,4 @@ class SettingsBridge : public QObject { static QString toJsKey(const QString& storePath); SettingsStore* store_; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/SharechainBridge.cpp b/ui/c2pool-qt/src/bridges/SharechainBridge.cpp index 8154ee270..b9a40e064 100644 --- a/ui/c2pool-qt/src/bridges/SharechainBridge.cpp +++ b/ui/c2pool-qt/src/bridges/SharechainBridge.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "SharechainBridge.hpp" #include "ApiClient.hpp" @@ -306,4 +307,4 @@ void SharechainBridge::onReconnectTimer() if (!streamRequested_) return; openStream(); emit tipReconnected(); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/src/bridges/SharechainBridge.hpp b/ui/c2pool-qt/src/bridges/SharechainBridge.hpp index 887e40073..06a310a9a 100644 --- a/ui/c2pool-qt/src/bridges/SharechainBridge.hpp +++ b/ui/c2pool-qt/src/bridges/SharechainBridge.hpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // SharechainBridge — QtWebChannel transport for the embedded JS // Explorer bundle. Mirrors the 9-operation Transport interface from // web-static/sharechain-explorer/src/transport/types.ts so the JS @@ -107,4 +108,4 @@ private slots: QTimer* reconnectTimer_ = nullptr; int reconnectAttempts_ = 0; bool streamRequested_ = false; -}; +}; \ No newline at end of file diff --git a/ui/c2pool-qt/src/main.cpp b/ui/c2pool-qt/src/main.cpp index 75838288a..c44c2bf63 100644 --- a/ui/c2pool-qt/src/main.cpp +++ b/ui/c2pool-qt/src/main.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later #include "MainWindow.hpp" #include "SettingsStore.hpp" @@ -18,4 +19,4 @@ int main(int argc, char* argv[]) MainWindow window(&settings); window.show(); return app.exec(); -} +} \ No newline at end of file diff --git a/ui/c2pool-qt/test/test_embedded_leak.cpp b/ui/c2pool-qt/test/test_embedded_leak.cpp index 4c399f3ca..1e43b4b2d 100644 --- a/ui/c2pool-qt/test/test_embedded_leak.cpp +++ b/ui/c2pool-qt/test/test_embedded_leak.cpp @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: AGPL-3.0-or-later // test_embedded_leak — Qt step 14 leak-regression harness. // // Asserts that mount→destroy × 100 of PageEmbedded does not leave @@ -179,4 +180,4 @@ int main(int argc, char* argv[]) // and xvfb-run if the runner has no EGL/OpenGL. QApplication app(argc, argv); return runHarness(); -} +} \ No newline at end of file