**1 Corinthians 2:6-8**  
Here is what I get from the Greek:
><sup>6</sup>But, we are talking of the wisdom of perfect things ‒ wisdom, though, not of this age, nor of the rulers of this age, *about* things that will pass away.  
<sup><sup><sup></sup></sup></sup><sup>7</sup> No, we are talking of the wisdom of God! About a mystery ‒ hidden wisdom ordained by God before the ages, for our glory. <sup>8</sup> Wisdom none of the rulers of this age has understood. For had they understood, by no means would they have crucified the Lord of glory.

Details (Click to enlarge):
[![enter image description here][1]][1]


In verse 6, Paul is contrasting wisdom of "perfect things" (*τοῖς τελείοις*) with wisdom of "passing away things" (*τῶν καταργουμένων*), as he did in 1 Corinthians 13:10, i.e. "that which is perfect" (*τὸ τέλειον*) with "that which is ... done away" (*τὸ ... καταργηθήσεται*)

>But when **that which is perfect <sup>*τὸ τέλειον*</sup>** is come, then **that which is<sup>*τὸ*</sup>** in part shall be **done away <sup>καταργηθήσεται*</sup>**.  
-- 1 Corinthians 13:10 (KJV)

In regard to who these "rulers" might be, Paul here uses *ἀρχόντων* (from *ἄρχων* : [Strong's G758][2] - archōn), which is the standard Greek word for rulers/princes of this world, whereas in Ephesians 6:12 (which you cite), he uses the word *κοσμοκράτορας* (from *κοσμοκράτωρ*: [Strong's G2888][3] - kosmokratōr).

*κοσμοκράτωρ* only occurs once in the New Testament, in Ephesians 6:12. If Paul wanted to inform his readers that the rulers in 1 Corinthians 2:6 were "spiritual beings in heavenly places", then he would have used *κοσμοκράτωρ* rather than *ἄρχων*.

###Conclusion
In 1 Corinthians 2:6-8, Paul is talking about **the rulers** of the people, i.e. those to whom Pilate spoke:
><sup>13</sup>And Pilate, when he had called together the chief priests and **the rulers <sup>τοὺς ἄρχοντας</sup>** and the people,  
<sup>14</sup>Said unto them, Ye have brought this man unto me, as one that perverteth the people: and, behold, I, having examined him before you, have found no fault in this man touching those things whereof ye accuse him:  
-- Luke 23:13-14 (KJV) 

The very ones who later stood taunting Jesus as he hung on the cross:
><sup>35</sup>And the people stood beholding. And **the rulers <sup>οἱ ἄρχοντες</sup>** also with them derided him, saying, He saved others; let him save himself, if he be Christ, the chosen of God.  
-- Luke 23:35 (KJV)


  [1]: https://i.sstatic.net/G63n9.png
  [2]: https://www.blueletterbible.org/lang/Lexicon/Lexicon.cfm?strongs=G758&t=KJV
  [3]: https://www.blueletterbible.org/lang/Lexicon/Lexicon.cfm?strongs=G2888&t=KJV