I think that very often the idea of 'constraint' appears in mathematics. For example, when a triangle is considered, 3 points are constrained not to be co-linear, and then we try to discover the implications of this initial constraint, when the rules of logic are applied to it.
Doing this, we discover implications which, although present from the beginning, are not immediately apparent, so essentially we discover what we have already assumed without knowing it.
So in this very general setting, my 2 questions are:
1) What is the most general way to define and separate "the rules of logic" from "the things to which the rules are applied" ?
2) If the above separation can be made, is there some "minimal constraint" on the things upon which logic is applied, enabling us to see the workings of logic in the most pure form, i.e. with minimal inteference with the properties of things upon which logic acts?
For example, suppose we start with the constraint: let S be an object. Nothing else is assumed. Is there something meaningful and "non-trivial" implied by this constraint?
Maybe some of the words used above are not as well-defined as needed, but i leave them unchanged hoping that the direction towards which i'm asking for guidance is not very unclear.
EDIT: (too long for a comment) based on the answer of Mauro ALLEGRANZA.
As humans we have the innate ability to separate words and construct sentences with persistent meanings. This seems to me a very great capability, which pre-exists even relative to other very basic "mathematical" ones, e.g. the capability to duplicate things, to count things, to conceive concepts like "for every", to conceive the set of natural numbers...
So is there a universally accepted foundation of logic which clearly separates the ultimate basic concepts from all the rest?
Am i wrong in thinking that all known formalizations address concepts already well-understood relative to the still obscure foundations of logic, (e.g. the border between physical language and natural numbers) resulting in an ever-present foundational mist?
EDIT 2 (motivated by the answer of Bumble): I wonder whether logical constants include (besides concepts as 'and','or','if' etc.) the natural numbers too. They seem absolutely necessary for "primitive" logical processes like the separation of words and the formulation of sentences. If this is true, then the clear separation of "logic" from "objects upon which logic acts" becomes problematic, as natural numbers appear to be some sort of "common ground". Is it the only common ground? Could geometric shapes also exist in logic? (for example, we have the ability to spot "cyclical reasoning". Is this just a play of words, or is it produced by the idea of a cycle, or a closed curve in general?)