AD plugin or utility that generates unique uidnumber / gidnumber on creation The 2019 Stack Overflow Developer Survey Results Are InHow to automate RFC2307 attributes in Active Directory?WipeDrive Utility?Vista's Unique Keyboard ShortcutsWhat's the reverse DNS command line utility?Debian Linux: Find Application that generates lots of Incoming TrafficWindows AD, bulk user creation, homedrv creation via commandlineuser SID unique?Using udev to create a character device based on a driver being loadedLDAP User Management Tool for Mac 10.7.1File creation time on Windows vs LinuxWindows utility list compatible devices with linux

What does "fetching by region is not available for SAM files" means?

Is a "Democratic" Oligarchy-Style System Possible?

The difference between dialogue marks

Why do UK politicians seemingly ignore opinion polls on Brexit?

What is the motivation for a law requiring 2 parties to consent for recording a conversation

Aging parents with no investments

What does ひと匙 mean in this manga and has it been used colloquially?

If a Druid sees an animal’s corpse, can they wild shape into that animal?

Earliest use of the term "Galois extension"?

How to type this arrow in math mode?

Protecting Dualbooting Windows from dangerous code (like rm -rf)

How to deal with fear of taking dependencies

How to answer pointed "are you quitting" questioning when I don't want them to suspect

Loose spokes after only a few rides

Can one be advised by a professor who is very far away?

How to notate time signature switching consistently every measure

Did 3000BC Egyptians use meteoric iron weapons?

Can someone be penalized for an "unlawful" act if no penalty is specified?

Identify This Plant (Flower)

Is flight data recorder erased after every flight?

Are children permitted to help build the Beis Hamikdash?

Why didn't the Event Horizon Telescope team mention Sagittarius A*?

How to obtain Confidence Intervals for a LASSO regression?

Why isn't airport relocation done gradually?



AD plugin or utility that generates unique uidnumber / gidnumber on creation



The 2019 Stack Overflow Developer Survey Results Are InHow to automate RFC2307 attributes in Active Directory?WipeDrive Utility?Vista's Unique Keyboard ShortcutsWhat's the reverse DNS command line utility?Debian Linux: Find Application that generates lots of Incoming TrafficWindows AD, bulk user creation, homedrv creation via commandlineuser SID unique?Using udev to create a character device based on a driver being loadedLDAP User Management Tool for Mac 10.7.1File creation time on Windows vs LinuxWindows utility list compatible devices with linux



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








6















I'm looking for either:



A plugin that will auto-generate a unique uidNumber attribute value for new users and a unique gidNumber attribute value for new groups upon creation.



A configurable user/group management application that can generate the unique values above as well as populate the various other attributes required for Linux integration



We present are using a home-grown script and web page to do all this, but we're looking for something that we don't have to maintain and a little more polished.



Anyone know of a good tool that fits the bill?



Thanks!










share|improve this question






















  • You might want to base generation on objectguid, which is unique forest wide and can be generated on the fly.

    – Jim B
    May 17 '16 at 0:16

















6















I'm looking for either:



A plugin that will auto-generate a unique uidNumber attribute value for new users and a unique gidNumber attribute value for new groups upon creation.



A configurable user/group management application that can generate the unique values above as well as populate the various other attributes required for Linux integration



We present are using a home-grown script and web page to do all this, but we're looking for something that we don't have to maintain and a little more polished.



Anyone know of a good tool that fits the bill?



Thanks!










share|improve this question






















  • You might want to base generation on objectguid, which is unique forest wide and can be generated on the fly.

    – Jim B
    May 17 '16 at 0:16













6












6








6


2






I'm looking for either:



A plugin that will auto-generate a unique uidNumber attribute value for new users and a unique gidNumber attribute value for new groups upon creation.



A configurable user/group management application that can generate the unique values above as well as populate the various other attributes required for Linux integration



We present are using a home-grown script and web page to do all this, but we're looking for something that we don't have to maintain and a little more polished.



Anyone know of a good tool that fits the bill?



Thanks!










share|improve this question














I'm looking for either:



A plugin that will auto-generate a unique uidNumber attribute value for new users and a unique gidNumber attribute value for new groups upon creation.



A configurable user/group management application that can generate the unique values above as well as populate the various other attributes required for Linux integration



We present are using a home-grown script and web page to do all this, but we're looking for something that we don't have to maintain and a little more polished.



Anyone know of a good tool that fits the bill?



Thanks!







linux windows attributes






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Mar 5 '13 at 16:17









jasonpvpjasonpvp

3112




3112












  • You might want to base generation on objectguid, which is unique forest wide and can be generated on the fly.

    – Jim B
    May 17 '16 at 0:16

















  • You might want to base generation on objectguid, which is unique forest wide and can be generated on the fly.

    – Jim B
    May 17 '16 at 0:16
















You might want to base generation on objectguid, which is unique forest wide and can be generated on the fly.

– Jim B
May 17 '16 at 0:16





You might want to base generation on objectguid, which is unique forest wide and can be generated on the fly.

– Jim B
May 17 '16 at 0:16










2 Answers
2






active

oldest

votes


















3














I don't know of any existing tools that actually trigger on creation. Though like Nic mentioned, it is hypothetically possible to write something that could do that.



But realistically, how often are users/groups getting created outside of already automated processes? If they're not already, your existing provisioning processes should be augmented to add the relevant RFC2307 attributes also described in this TechNet blog post. For the stragglers that are created manually, you can have a script run at whatever interval you like that looks for objects missing the attributes and populating them as necessary.



In our environment, the script we have runs every 5 min on the DC holding the PDC Emulator role. But we could probably drop it down to once a minute without much additional impact. We also generate our UID/GID values from an algorithm that's based on the object's SID rather than a simple auto-incrementing value. It has the benefit that they're guaranteed* unique between domains/forests and we don't need to do any lookups to find the next value or make sure the value we want to use isn't already in use. I can post that function if you'd like. But it sounds like you guys may already have your own system for that.



*Guaranteed = as much as you can guarantee that two domains won't be created with the same randomly generated domain ID.



Edit: By request, here's the Powershell function we use to generate UIDs/GIDs from a SID.



function Get-UidFromSid()
Get-UidFromSid

Calculate a UID from an existing Active Directory user via pipeline input.
#>







share|improve this answer

























  • Objectguid is guaranteed to be unique within the forest and generated on object creation

    – Jim B
    Jun 19 '16 at 15:29











  • Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

    – JimNim
    Jul 19 '17 at 15:55











  • Done. I also have C#, Bash, and Python versions as well.

    – Ryan Bolger
    Jul 23 '17 at 0:00


















1














You could assign the gidNumber attribute from a PowerShell script. To make it automatic, call the script as a scheduled task. I wrote a cmdlet called Initialize-GroupGids which assigns unique gids to AD groups, and can be customized for different environments with parameters.



But basically, you can just to do something like this in PowerShell.



# Find the highest GID used on any group in the domain
$highGid = Get-ADGroup -LDAPFilter "(gidNumber=*)" -Properties gidNumber |
Measure-Object -Property gidNumber -Maximum |
Select-Object -ExpandProperty Maximum

# Avoid assigning GIDs below 1000
$highGid = [Math]::max( $highGid, 1000 )

# Find every security group without a gidNumber, and give it one.
Get-ADGroup -LDAPFilter "(!gidNumber=*)" |
? $_.GroupCategory -eq "Security" |
$groups | Set-ADGroup -Add @ gidNumber=++$highGid


This could easily be adopted to work with users and uidNumbers too.



If you want the assignment of uids/gids to be instantaneous, Microsoft has an interesting technote about listening to change notifications from Active Directory via LDAP. I think that's a bit too sophisticated for PowerShell though.






share|improve this answer























    Your Answer








    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "2"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f484908%2fad-plugin-or-utility-that-generates-unique-uidnumber-gidnumber-on-creation%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    3














    I don't know of any existing tools that actually trigger on creation. Though like Nic mentioned, it is hypothetically possible to write something that could do that.



    But realistically, how often are users/groups getting created outside of already automated processes? If they're not already, your existing provisioning processes should be augmented to add the relevant RFC2307 attributes also described in this TechNet blog post. For the stragglers that are created manually, you can have a script run at whatever interval you like that looks for objects missing the attributes and populating them as necessary.



    In our environment, the script we have runs every 5 min on the DC holding the PDC Emulator role. But we could probably drop it down to once a minute without much additional impact. We also generate our UID/GID values from an algorithm that's based on the object's SID rather than a simple auto-incrementing value. It has the benefit that they're guaranteed* unique between domains/forests and we don't need to do any lookups to find the next value or make sure the value we want to use isn't already in use. I can post that function if you'd like. But it sounds like you guys may already have your own system for that.



    *Guaranteed = as much as you can guarantee that two domains won't be created with the same randomly generated domain ID.



    Edit: By request, here's the Powershell function we use to generate UIDs/GIDs from a SID.



    function Get-UidFromSid()
    Get-UidFromSid

    Calculate a UID from an existing Active Directory user via pipeline input.
    #>







    share|improve this answer

























    • Objectguid is guaranteed to be unique within the forest and generated on object creation

      – Jim B
      Jun 19 '16 at 15:29











    • Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

      – JimNim
      Jul 19 '17 at 15:55











    • Done. I also have C#, Bash, and Python versions as well.

      – Ryan Bolger
      Jul 23 '17 at 0:00















    3














    I don't know of any existing tools that actually trigger on creation. Though like Nic mentioned, it is hypothetically possible to write something that could do that.



    But realistically, how often are users/groups getting created outside of already automated processes? If they're not already, your existing provisioning processes should be augmented to add the relevant RFC2307 attributes also described in this TechNet blog post. For the stragglers that are created manually, you can have a script run at whatever interval you like that looks for objects missing the attributes and populating them as necessary.



    In our environment, the script we have runs every 5 min on the DC holding the PDC Emulator role. But we could probably drop it down to once a minute without much additional impact. We also generate our UID/GID values from an algorithm that's based on the object's SID rather than a simple auto-incrementing value. It has the benefit that they're guaranteed* unique between domains/forests and we don't need to do any lookups to find the next value or make sure the value we want to use isn't already in use. I can post that function if you'd like. But it sounds like you guys may already have your own system for that.



    *Guaranteed = as much as you can guarantee that two domains won't be created with the same randomly generated domain ID.



    Edit: By request, here's the Powershell function we use to generate UIDs/GIDs from a SID.



    function Get-UidFromSid()
    Get-UidFromSid

    Calculate a UID from an existing Active Directory user via pipeline input.
    #>







    share|improve this answer

























    • Objectguid is guaranteed to be unique within the forest and generated on object creation

      – Jim B
      Jun 19 '16 at 15:29











    • Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

      – JimNim
      Jul 19 '17 at 15:55











    • Done. I also have C#, Bash, and Python versions as well.

      – Ryan Bolger
      Jul 23 '17 at 0:00













    3












    3








    3







    I don't know of any existing tools that actually trigger on creation. Though like Nic mentioned, it is hypothetically possible to write something that could do that.



    But realistically, how often are users/groups getting created outside of already automated processes? If they're not already, your existing provisioning processes should be augmented to add the relevant RFC2307 attributes also described in this TechNet blog post. For the stragglers that are created manually, you can have a script run at whatever interval you like that looks for objects missing the attributes and populating them as necessary.



    In our environment, the script we have runs every 5 min on the DC holding the PDC Emulator role. But we could probably drop it down to once a minute without much additional impact. We also generate our UID/GID values from an algorithm that's based on the object's SID rather than a simple auto-incrementing value. It has the benefit that they're guaranteed* unique between domains/forests and we don't need to do any lookups to find the next value or make sure the value we want to use isn't already in use. I can post that function if you'd like. But it sounds like you guys may already have your own system for that.



    *Guaranteed = as much as you can guarantee that two domains won't be created with the same randomly generated domain ID.



    Edit: By request, here's the Powershell function we use to generate UIDs/GIDs from a SID.



    function Get-UidFromSid()
    Get-UidFromSid

    Calculate a UID from an existing Active Directory user via pipeline input.
    #>







    share|improve this answer















    I don't know of any existing tools that actually trigger on creation. Though like Nic mentioned, it is hypothetically possible to write something that could do that.



    But realistically, how often are users/groups getting created outside of already automated processes? If they're not already, your existing provisioning processes should be augmented to add the relevant RFC2307 attributes also described in this TechNet blog post. For the stragglers that are created manually, you can have a script run at whatever interval you like that looks for objects missing the attributes and populating them as necessary.



    In our environment, the script we have runs every 5 min on the DC holding the PDC Emulator role. But we could probably drop it down to once a minute without much additional impact. We also generate our UID/GID values from an algorithm that's based on the object's SID rather than a simple auto-incrementing value. It has the benefit that they're guaranteed* unique between domains/forests and we don't need to do any lookups to find the next value or make sure the value we want to use isn't already in use. I can post that function if you'd like. But it sounds like you guys may already have your own system for that.



    *Guaranteed = as much as you can guarantee that two domains won't be created with the same randomly generated domain ID.



    Edit: By request, here's the Powershell function we use to generate UIDs/GIDs from a SID.



    function Get-UidFromSid()
    Get-UidFromSid

    Calculate a UID from an existing Active Directory user via pipeline input.
    #>








    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited 13 hours ago









    Jonathon Reinhart

    1581115




    1581115










    answered Jan 12 '16 at 7:05









    Ryan BolgerRyan Bolger

    14.1k23051




    14.1k23051












    • Objectguid is guaranteed to be unique within the forest and generated on object creation

      – Jim B
      Jun 19 '16 at 15:29











    • Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

      – JimNim
      Jul 19 '17 at 15:55











    • Done. I also have C#, Bash, and Python versions as well.

      – Ryan Bolger
      Jul 23 '17 at 0:00

















    • Objectguid is guaranteed to be unique within the forest and generated on object creation

      – Jim B
      Jun 19 '16 at 15:29











    • Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

      – JimNim
      Jul 19 '17 at 15:55











    • Done. I also have C#, Bash, and Python versions as well.

      – Ryan Bolger
      Jul 23 '17 at 0:00
















    Objectguid is guaranteed to be unique within the forest and generated on object creation

    – Jim B
    Jun 19 '16 at 15:29





    Objectguid is guaranteed to be unique within the forest and generated on object creation

    – Jim B
    Jun 19 '16 at 15:29













    Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

    – JimNim
    Jul 19 '17 at 15:55





    Ryan, I'd be interested to see the function you mentioned, if that's something you're still able to provide - I believe it would add value to the original answer as an edit too.

    – JimNim
    Jul 19 '17 at 15:55













    Done. I also have C#, Bash, and Python versions as well.

    – Ryan Bolger
    Jul 23 '17 at 0:00





    Done. I also have C#, Bash, and Python versions as well.

    – Ryan Bolger
    Jul 23 '17 at 0:00













    1














    You could assign the gidNumber attribute from a PowerShell script. To make it automatic, call the script as a scheduled task. I wrote a cmdlet called Initialize-GroupGids which assigns unique gids to AD groups, and can be customized for different environments with parameters.



    But basically, you can just to do something like this in PowerShell.



    # Find the highest GID used on any group in the domain
    $highGid = Get-ADGroup -LDAPFilter "(gidNumber=*)" -Properties gidNumber |
    Measure-Object -Property gidNumber -Maximum |
    Select-Object -ExpandProperty Maximum

    # Avoid assigning GIDs below 1000
    $highGid = [Math]::max( $highGid, 1000 )

    # Find every security group without a gidNumber, and give it one.
    Get-ADGroup -LDAPFilter "(!gidNumber=*)" |
    ? $_.GroupCategory -eq "Security" |
    $groups | Set-ADGroup -Add @ gidNumber=++$highGid


    This could easily be adopted to work with users and uidNumbers too.



    If you want the assignment of uids/gids to be instantaneous, Microsoft has an interesting technote about listening to change notifications from Active Directory via LDAP. I think that's a bit too sophisticated for PowerShell though.






    share|improve this answer



























      1














      You could assign the gidNumber attribute from a PowerShell script. To make it automatic, call the script as a scheduled task. I wrote a cmdlet called Initialize-GroupGids which assigns unique gids to AD groups, and can be customized for different environments with parameters.



      But basically, you can just to do something like this in PowerShell.



      # Find the highest GID used on any group in the domain
      $highGid = Get-ADGroup -LDAPFilter "(gidNumber=*)" -Properties gidNumber |
      Measure-Object -Property gidNumber -Maximum |
      Select-Object -ExpandProperty Maximum

      # Avoid assigning GIDs below 1000
      $highGid = [Math]::max( $highGid, 1000 )

      # Find every security group without a gidNumber, and give it one.
      Get-ADGroup -LDAPFilter "(!gidNumber=*)" |
      ? $_.GroupCategory -eq "Security" |
      $groups | Set-ADGroup -Add @ gidNumber=++$highGid


      This could easily be adopted to work with users and uidNumbers too.



      If you want the assignment of uids/gids to be instantaneous, Microsoft has an interesting technote about listening to change notifications from Active Directory via LDAP. I think that's a bit too sophisticated for PowerShell though.






      share|improve this answer

























        1












        1








        1







        You could assign the gidNumber attribute from a PowerShell script. To make it automatic, call the script as a scheduled task. I wrote a cmdlet called Initialize-GroupGids which assigns unique gids to AD groups, and can be customized for different environments with parameters.



        But basically, you can just to do something like this in PowerShell.



        # Find the highest GID used on any group in the domain
        $highGid = Get-ADGroup -LDAPFilter "(gidNumber=*)" -Properties gidNumber |
        Measure-Object -Property gidNumber -Maximum |
        Select-Object -ExpandProperty Maximum

        # Avoid assigning GIDs below 1000
        $highGid = [Math]::max( $highGid, 1000 )

        # Find every security group without a gidNumber, and give it one.
        Get-ADGroup -LDAPFilter "(!gidNumber=*)" |
        ? $_.GroupCategory -eq "Security" |
        $groups | Set-ADGroup -Add @ gidNumber=++$highGid


        This could easily be adopted to work with users and uidNumbers too.



        If you want the assignment of uids/gids to be instantaneous, Microsoft has an interesting technote about listening to change notifications from Active Directory via LDAP. I think that's a bit too sophisticated for PowerShell though.






        share|improve this answer













        You could assign the gidNumber attribute from a PowerShell script. To make it automatic, call the script as a scheduled task. I wrote a cmdlet called Initialize-GroupGids which assigns unique gids to AD groups, and can be customized for different environments with parameters.



        But basically, you can just to do something like this in PowerShell.



        # Find the highest GID used on any group in the domain
        $highGid = Get-ADGroup -LDAPFilter "(gidNumber=*)" -Properties gidNumber |
        Measure-Object -Property gidNumber -Maximum |
        Select-Object -ExpandProperty Maximum

        # Avoid assigning GIDs below 1000
        $highGid = [Math]::max( $highGid, 1000 )

        # Find every security group without a gidNumber, and give it one.
        Get-ADGroup -LDAPFilter "(!gidNumber=*)" |
        ? $_.GroupCategory -eq "Security" |
        $groups | Set-ADGroup -Add @ gidNumber=++$highGid


        This could easily be adopted to work with users and uidNumbers too.



        If you want the assignment of uids/gids to be instantaneous, Microsoft has an interesting technote about listening to change notifications from Active Directory via LDAP. I think that's a bit too sophisticated for PowerShell though.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Apr 13 '13 at 19:52









        NicNic

        8,862144691




        8,862144691



























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Server Fault!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f484908%2fad-plugin-or-utility-that-generates-unique-uidnumber-gidnumber-on-creation%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            How to make RAID controller rescan devices The 2019 Stack Overflow Developer Survey Results Are InLSI MegaRAID SAS 9261-8i: Disk isn't recognized after replacementHow to monitor the hard disk status behind Dell PERC H710 Raid Controller with CentOS 6?LSI MegaRAID - Recreate missing RAID 1 arrayext. 2-bay USB-Drive with RAID: btrfs RAID vs built-in RAIDInvalid SAS topologyDoes enabling JBOD mode on LSI based controllers affect existing logical disks/arrays?Why is there a shift between the WWN reported from the controller and the Linux system?Optimal RAID 6+0 Setup for 40+ 4TB DisksAccidental SAS cable removal

            How can I have a shield and a way of attacking at distance at the same time? The 2019 Stack Overflow Developer Survey Results Are InDoes the Thrown property mean I can attack with my DEX?Is it possible to build a custom weapon, and if so, how will my character be able to use it?Can the Ghost Touch weapon property allow an attacker to perform incorporeal touch attacks?The DM allowed me to wield two shields, how can I get the most AC and HP, as a Bear Barbarian?Are there ways other than Kensei Weapons or Hex Warrior to use an ability other than STR for non-finesse melee weapons?Cheapest way to cast spells with sword and (heavy) shield?Is this homebrew “Throwing Weapons Master” feat balanced?Can Hexblade warlocks use a staff and shield?Are there any balance issues with allowing thrown Javelins to be drawn for free like ammunition weapons?Does an unattuned Frost Brand weapon still glow in freezing temperatures?Does a druid starting with a bow start with no arrows?Is it possible to build a custom weapon, and if so, how will my character be able to use it?

            Unbreakable Formation vs. Cry of the Carnarium The 2019 Stack Overflow Developer Survey Results Are InCan an indestructible creature die by a combination of damage and -X/-X effects?Can a non-instant or sorcery ever have flashback?do creatures created after a “all creatures get -1/-1 until end of turn” instant get -1/-1 as well?What happens when I target an indestructible card with an “if that would die this turn, exile it instead” effect?Exalted trigger timingWhat happens when a non-token creature loses all abilities, is exiled, then returns?Does the spell cast with Yahenni's Expertise resolve before state-based effects are checked?What happens if Always Watching is destroyed mid-combat?MTG: Abilities lost when exiled?Under which controller does a stolen permanent come into play after being exiled?